Introduction
Introduction Statistics Contact Development Disclaimer Help
index.md - sites - public wiki contents of suckless.org
git clone git://git.suckless.org/sites
Log
Files
Refs
---
index.md (4125B)
---
1 Right click to plumb
2 ====================
3 Pretty much like plan9's acme and plumber: right-click some selected tex…
4 send it to the plumbing program of your choosing:
5
6 * open an URL in a browser
7 * view an image, PDF, ...
8 * jump from logs to editor, at the specified line/col
9 * etc
10
11 The shell current working directory is set by the shell via `OSC 7` (bor…
12 from vte, see `/etc/profile.d/vte.sh` if you have it installed).
13
14 For zsh :
15 __vte_urlencode() (
16 # This is important to make sure string manipulation is hand…
17 # byte-by-byte.
18 LC_ALL=C
19 str="$1"
20 while [ -n "$str" ]; do
21 safe="${str%%[!a-zA-Z0-9/:_\.\-\!\'\(\)~]*}"
22 printf "%s" "$safe"
23 str="${str#"$safe"}"
24 if [ -n "$str" ]; then
25 printf "%%%02X" "'$str"
26 str="${str#?}"
27 fi
28 done
29 )
30
31 __vte_osc7 () {
32 printf "\033]7;%s%s\a" "${HOSTNAME:-}" "$(__vte_urlencode "$…
33 }
34
35 [ -n "$ZSH_VERSION" ] && precmd_functions+=(__vte_osc7)
36
37 The patch itself only adds a `cwd` global and a button3 entry that will …
38 shell, change directory to cwd and run the plumber with the primary sele…
39 Maybe I should use pass cwd as an argument too, like plan9 plumber does.
40
41 The plumbing program can be defined via `config.h`:
42
43 static char plumber[] = "plumb.sh";
44
45 Download
46 --------
47 * [right\_click\_to\_plumb.diff](right_click_to_plumb.diff) (2017-09-11)
48
49 Authors
50 -------
51 * [jerome](http://blog.jardinmagique.info) <[email protected]>
52
53 A simpler plumb patch
54 =====================
55 The plumbing command is run in the working directory of the shell, with …
56 parameter the text selected with the mouse.
57
58 Configuration is done in config.h and an example is supplied in config.d…
59
60 static char *plumb_cmd = "plumb";
61
62 I made this version since I had a hard time understanding how the OSC 7 …
63 works and I preferred a full C implementation of a plumbing patch.
64
65 Download
66 --------
67 * [plumb\_without\_shell\_OSC.diff](plumb_without_shell_OSC.diff) (2018-…
68
69 Authors
70 -------
71 * [john](http://roxor.me) <[email protected]>
72
73 A simpler, more flexible plumb patch
74 ====================================
75 A further development on the previous patch to allow for specifying the …
76
77 static char *plumb_cmd[] = {"plumb", "-m", NULL, NULL};
78
79 My plumb utility takes on the stdin by default, and requires another opt…
80 be passed input on the command line, so I made this to allow for that. …
81 applied on its own, without the other patches. It replaces the first NU…
82 the current selection.
83
84 Download
85 --------
86 * [simple_plumb-0.8.5.diff](simple_plumb-0.8.5.diff) (2022-01-18)
87 * [simple_plumb.diff](simple_plumb.diff) (2020-04-10)
88
89 Authors
90 -------
91 * [dallin](https://dallinjdahl.github.io/) <[email protected]>
92 * [Alexander Arkhipov](gopher://mineeyes.cyou/) (0.8.5 port)
93
94 Double click to plumb
95 =====================
96 Adds additional functionality to the simple_plumb patch that allows the …
97 via double clicking while a mask key is held down.
98
99 This patch should be applied after simple_plumb.
100
101 Download
102 --------
103 * [simple\_plumb\_double\_click-0.8.5.diff](simple_plumb_double_click-0.…
104
105 Author
106 ------
107 * yasumori <[email protected]>
108
109 An even simpler plumb patch
110 ===========================
111 The differences of this patch to the simple, flexible plumb patch:
112
113 * The code for retrieving and setting the current working directory and …
114 same as newterm, if patching with newterm it is suggested to keep the …
115 no global variables and initialization, and current selection of plumb.
116 * Double-fork execution of the plumber program, while this may have no b…
117 that only launch in CLI, this may interfere with the swallow patch if …
118 * No arguments are passed to the plumber program, only the plumber progr…
119 * The plumb function can be passed to the mouse shortcuts in `config.h`,
120 instead of being hard-coded.
121
122 Download
123 --------
124 * [simpler\_plumb-0.9.diff](simpler_plumb-0.9.diff)
125
126 Author
127 ------
128 * sewn <[email protected]>
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.