resources:emacs_resources
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| resources:emacs_resources [2016/01/18 19:31] – anthony | resources:emacs_resources [2019/05/22 16:08] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Emacs Resources ====== | ||
| + | |||
| + | \\ | ||
| + | |||
| ====== Regular expressions ====== | ====== Regular expressions ====== | ||
| (" | (" | ||
| - | ====== Links to helpful pages ====== | + | ===== Links to helpful pages ===== |
| http:// | http:// | ||
| Line 10: | Line 14: | ||
| ---- | ---- | ||
| - | ====== Recipes | + | ===== Recipes ===== |
| \\ | \\ | ||
| \\ | \\ | ||
| - | ===== Replace single spaces after end of sentence with two spaces in Emacs ===== | + | ==== Replace single spaces after end of sentence with two spaces in Emacs ==== |
| < | < | ||
| Line 30: | Line 34: | ||
| ---- | ---- | ||
| - | ===== Emacs replacement trick ADC used when writing SPM table report tool ===== | + | ==== Emacs replacement trick ADC used when writing SPM table report tool ==== |
| (from [[internal: | (from [[internal: | ||
| Line 45: | Line 49: | ||
| ---- | ---- | ||
| - | ===== Emacs regexp for removing newline characters from text copied from Adobe PDF file ===== | + | ==== Emacs regexp for removing newline characters from text copied from Adobe PDF file ==== |
| [Originally from Anthony' | [Originally from Anthony' | ||
| Line 68: | Line 72: | ||
| ---- | ---- | ||
| + | ==== Add line break (RETURN) to end of all lines ==== | ||
| - | ===== Sort article lists by year using awk and sed ===== | + | [Put another way: insert spaces, insert empty line in between every line.] |
| - | [Originally from Anthony' | + | < |
| - | + | M-x replace-regexp | |
| - | Exported bibliography to clipboard in Zotero, pasted into Emacs to write new file: | + | .$[RET] |
| - | + | \&[C-q][C-j][RET] | |
| - | '' | + | |
| - | + | ||
| - | + | ||
| - | Try using awk to print column with year before whole rest of line | + | |
| - | + | ||
| - | <code bash> | + | |
| - | gawk ' | + | |
| </ | </ | ||
| - | Remove parens from FIRST (year) on a line: | + | " |
| - | <code bash> | + | C-q indicates something like " |
| - | sed -r 's/[(]([0-9]*[a-z]? | + | |
| - | </ | + | |
| - | Used rectangle register copy trick in Emacs to copy only first five chars (catches both 2012 and 2012b) and pasted ultimately to Excel column. | + | C-j inserts a line break (a RETURN keypress, but this might not be the most precise description). |
| \\ | \\ | ||
| ---- | ---- | ||
| - | |||
resources/emacs_resources.1453163506.txt.gz · Last modified: (external edit)
