summaryrefslogtreecommitdiff
path: root/.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines
diff options
context:
space:
mode:
authorSimeon Simeonov2015-02-04 21:41:42 +0100
committerSimeon Simeonov2015-02-04 21:41:42 +0100
commit897eee81de8b3f6adf0165f50e95600a7b89c20c (patch)
tree5ee19c07c40e822e15a6443e5db5601c28913454 /.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines
parent9a46567eb167e5aef4b2e760c5d6bdc4fe1ba06a (diff)
Standalone lisp and snippet repo
Diffstat (limited to '.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines')
-rw-r--r--.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines17
1 files changed, 0 insertions, 17 deletions
diff --git a/.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines b/.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines
deleted file mode 100644
index b4a1942..0000000
--- a/.emacs.d/mysnippets/text-mode/emacs-lisp-mode/file.read-lines
+++ /dev/null
@@ -1,17 +0,0 @@
1#name : read lines of a file
2#contributor : Xah Lee
3# --
4(defun read-lines (filePath)
5 "Return a list of lines in FILEPATH."
6 (with-temp-buffer
7 (insert-file-contents filePath)
8 (split-string
9 (buffer-string) "\n" t)) )
10
11;; process all lines
12(mapc
13 (lambda (aLine)
14 (message aLine) ; do your stuff here
15 )
16 (read-lines "inputFilePath")
17) \ No newline at end of file