Klimi's new dotfiles with stow.
25'ten fazla konu seçemezsiniz Konular bir harf veya rakamla başlamalı, kısa çizgiler ('-') içerebilir ve en fazla 35 karakter uzunluğunda olabilir.

18 satır
403 B

5 yıl önce
  1. # -*- mode: snippet -*-
  2. # contributor: Xah Lee (XahLee.org)
  3. # name: read lines of a file
  4. # key: x-file
  5. # --
  6. (defun read-lines (filePath)
  7. "Return a list of lines in FILEPATH."
  8. (with-temp-buffer
  9. (insert-file-contents filePath)
  10. (split-string
  11. (buffer-string) "\n" t)))
  12. ;; process all lines
  13. (mapc
  14. (lambda (aLine)
  15. (message aLine) ; do your stuff here
  16. )
  17. (read-lines "inputFilePath")
  18. )