Skip to content

Write the current URL

David-Apps edited this page Sep 18, 2023 · 5 revisions

This simple function writes the URL (or file name) of the current buffer to another buffer. If writing to a buffer in another session, the function writes the URL after the current line. # Write the file name to a buffer. # usage: <u [] function+u { db0 H- ebvar+ lsX if() { ![ -z "~0" ] if() { ebvar- enew r !echo '/'. bw } else { ebvar- e~0 r !echo '/'. eret } } else { ![ -z "0" ] if(*) { ebvar- enew r !echo "$EB_BASE" bw } else { ebvar- e0 r !echo "$EB_BASE" eret } } }