Remove unnecessary functions
This commit is contained in:
parent
0b01d4fc25
commit
7a7e356657
5 changed files with 14 additions and 37 deletions
|
@ -102,14 +102,14 @@
|
||||||
(insert "* places\n** visited"))
|
(insert "* places\n** visited"))
|
||||||
(insert "\n** visited"))))
|
(insert "\n** visited"))))
|
||||||
|
|
||||||
(defun finddw ()
|
(defun findweb ()
|
||||||
"Find or create heading for DW posts"
|
"Find or create heading for website posts"
|
||||||
(filedate)
|
(filedate)
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(if (not (search-forward "* dw" nil t))
|
(if (not (search-forward "* post" nil t))
|
||||||
(progn
|
(progn
|
||||||
(goto-char (point-max))
|
(goto-char (point-max))
|
||||||
(insert "* dw"))))
|
(insert "* post"))))
|
||||||
|
|
||||||
(defun therating ()
|
(defun therating ()
|
||||||
"Rate some media"
|
"Rate some media"
|
||||||
|
@ -195,10 +195,6 @@
|
||||||
(file+function "" findread)
|
(file+function "" findread)
|
||||||
"* %^{Author} /%^{Title}/%(therating)%(theworkbook)"
|
"* %^{Author} /%^{Title}/%(therating)%(theworkbook)"
|
||||||
:jump-to-captured t)
|
:jump-to-captured t)
|
||||||
("d" "DW post" entry
|
|
||||||
(file+function "" finddw)
|
|
||||||
"* %^{Title}\n%?"
|
|
||||||
:jump-to-captured t)
|
|
||||||
("f" "Watched film" entry
|
("f" "Watched film" entry
|
||||||
(file+function "" findwatched)
|
(file+function "" findwatched)
|
||||||
"* %^{Title} (%^{Year})%(therating)"
|
"* %^{Title} (%^{Year})%(therating)"
|
||||||
|
@ -227,6 +223,10 @@
|
||||||
(file+function "" findreading)
|
(file+function "" findreading)
|
||||||
"* %^{Author} /%^{Title}/%(theworkbook)\n%(bookcalc)%?"
|
"* %^{Author} /%^{Title}/%(theworkbook)\n%(bookcalc)%?"
|
||||||
:jump-to-captured t)
|
:jump-to-captured t)
|
||||||
|
("w" "Website post" entry
|
||||||
|
(file+function "" findweb)
|
||||||
|
"* %^{Title}\n%?"
|
||||||
|
:jump-to-captured t)
|
||||||
("1" "Completed game" entry
|
("1" "Completed game" entry
|
||||||
(file+function "" findhundred)
|
(file+function "" findhundred)
|
||||||
"* %^{Title} (%setconsole)"
|
"* %^{Title} (%setconsole)"
|
||||||
|
|
|
@ -2,25 +2,14 @@
|
||||||
"Insert HTML link to a DW personal account"
|
"Insert HTML link to a DW personal account"
|
||||||
(interactive)
|
(interactive)
|
||||||
(setq theuser (read-string "DW username: "))
|
(setq theuser (read-string "DW username: "))
|
||||||
(setq ao3 (y-or-n-p "For AO3?"))
|
(setq userdisplay (subst-char-in-string ?- ?_ theuser))
|
||||||
(if ao3
|
(setq userlink (subst-char-in-string ?_ ?- theuser))
|
||||||
(insert (concat "<a href=\"https://" theuser ".dreamwidth.org/profile\" rel=\"nofollow\"><img src=\"https://www.dreamwidth.org/img/silk/identity/user.png\" width=\"17\" height=\"17\" /></a><b><a href=\"https://" theuser ".dreamwidth.org\" rel=\"nofollow\">" theuser "</a></b>"))
|
(insert (concat "<a href=\"https://" userlink ".dreamwidth.org/profile\">~</a><a href=\"https://" userlink ".dreamwidth.org\">" userdisplay "</a>")))
|
||||||
(insert (concat "<span style=\"white-space: nowrap;\" class=\"ljuser\"><a href=\"https://" theuser ".dreamwidth.org/profile\"><img src=\"https://www.dreamwidth.org/img/silk/identity/user.png\" alt=\"[personal profile]\" width=\"17\" height=\"17\" style=\"vertical-align: text-bottom; border: 0; padding-right: 1px;\" /></a><a href=\"https://" theuser ".dreamwidth.org/\"><b>" theuser "</b></a></span>"))))
|
|
||||||
|
|
||||||
(defun dwcomm ()
|
(defun dwcomm ()
|
||||||
"Insert HTML link to a DW community"
|
"Insert HTML link to a DW community"
|
||||||
(interactive)
|
(interactive)
|
||||||
(setq theuser (read-string "DW comm name: "))
|
(setq theuser (read-string "DW comm name: "))
|
||||||
(setq ao3 (y-or-n-p "For AO3?"))
|
(setq userdisplay (subst-char-in-string ?- ?_ theuser))
|
||||||
(if ao3
|
(setq userlink (subst-char-in-string ?_ ?- theuser))
|
||||||
(insert (concat "<a href=\"https://" theuser ".dreamwidth.org/profile\" rel=\"nofollow\"><img src=\"https://www.dreamwidth.org/img/silk/identity/community.png\" width=\"17\" height=\"17\" /></a><b><a href=\"https://" theuser ".dreamwidth.org\" rel=\"nofollow\">" theuser "</a></b>"))
|
(insert (concat "<a href=\"https://" userlink ".dreamwidth.org/profile\">/</a><a href=\"https://" userlink ".dreamwidth.org\">" userdisplay "</a>")))
|
||||||
(insert (concat "<span style=\"white-space: nowrap;\" class=\"ljuser\"><a href=\"https://" theuser ".dreamwidth.org/profile\"><img src=\"https://www.dreamwidth.org/img/silk/identity/community.png\" alt=\"[community profile]\" width=\"17\" height=\"17\" style=\"vertical-align: text-bottom; border: 0; padding-right: 1px;\" /></a><a href=\"https://" theuser ".dreamwidth.org/\"><b>" theuser "</b></a></span>"))))
|
|
||||||
|
|
||||||
(defun ao3user ()
|
|
||||||
"Insert HTML link to an AO3 user"
|
|
||||||
(interactive)
|
|
||||||
(setq theuser (read-string "AO3 username: "))
|
|
||||||
(setq ao3 (y-or-n-p "For AO3?"))
|
|
||||||
(if ao3
|
|
||||||
(insert (concat "<a href=\"https://archiveofourown.org/users/" theuser "/profile\" rel=\"nofollow\"><img src=\"https://p.dreamwidth.org/b164c54b26e4/-/archiveofourown.org/favicon.ico\" width=\"16\" height=\"16\" /></a><b><a href=\"https://archiveofourown.org/users/" theuser "\" rel=\"nofollow\">" theuser "</a></b>"))
|
|
||||||
(insert (concat "<span style=\"white-space: nowrap;\" class=\"ljuser\"><a href=\"https://archiveofourown.org/users/" theuser "/profile\"><img src=\"https://p.dreamwidth.org/b164c54b26e4/-/archiveofourown.org/favicon.ico\" alt=\"[archiveofourown.org profile]\" width=\"16\" height=\"16\" style=\"vertical-align: text-bottom; border: 0; padding-right: 1px;\" /></a><a href=\"https://archiveofourown.org/users/" theuser "\"><b>" theuser "</b></a></span>"))))
|
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
# name: dreamwidth-cut
|
|
||||||
# key: dwcut
|
|
||||||
# --
|
|
||||||
@@html:<cut text="$1">@@$0@@html:</cut>@@
|
|
|
@ -1,4 +0,0 @@
|
||||||
# name: dreamwidth-user
|
|
||||||
# key: dwuser
|
|
||||||
# --
|
|
||||||
@@html:<user name="$1">@@$0
|
|
|
@ -1,4 +0,0 @@
|
||||||
# name: site-user
|
|
||||||
# key: siteuser
|
|
||||||
# --
|
|
||||||
@@html:<user name="$1" site="$2">@@$0
|
|
Loading…
Add table
Add a link
Reference in a new issue