138
edits
No edit summary |
|||
| (33 intermediate revisions by 6 users not shown) | |||
| Line 4: | Line 4: | ||
== Running Weechat == | == Running Weechat == | ||
weechat is installed on azazel, the main login box. | |||
butlerx has written a bash script to get you started with weechat, run: | |||
~edu/confweechat | |||
/ | |||
Copy and paste that into your terminal command line, hit enter, and give yourself a pat on the back. | Copy and paste that into your terminal command line, hit enter, and give yourself a pat on the back. | ||
If you'd like to have a look before you run it, which you should its on [[https://github.com/redbrick/eduScripts/blob/master/confweechat Github]] | |||
Now just run | |||
weechat | |||
to chat to everyone | |||
== Basic use == | == Basic use == | ||
| Line 29: | Line 25: | ||
When you start Weechat, you won't get connected to a server or channel. To connect to Redbrick's IRC sever, type: | When you start Weechat, you won't get connected to a server or channel. To connect to Redbrick's IRC sever, type: | ||
/connect irc.redbrick.dcu.ie | |||
Then to join #lobby: | Then to join #lobby: | ||
/join #lobby | |||
As well as showing you how IRC clients (such as Weechat or Irssi or whatever) connect to stuff, this should also show you how to connect to other servers and channels outside of Redbrick. | As well as showing you how IRC clients (such as Weechat or Irssi or whatever) connect to stuff, this should also show you how to connect to other servers and channels outside of Redbrick. | ||
| Line 42: | Line 38: | ||
Like Irssi, you can move between windows/buffers using Alt+<num>. You can also type /buffer <num> (similar to /win <num> in Irssi). | Like Irssi, you can move between windows/buffers using Alt+<num>. You can also type /buffer <num> (similar to /win <num> in Irssi). | ||
Unlike irssi you can do Alt+j then <num> to change to a number greather the 10 . | |||
F5 and F6 move to the predecessing and successing buffer, respectively. | F5 and F6 move to the predecessing and successing buffer, respectively. | ||
| Line 47: | Line 44: | ||
You can move buffers (chat windows) with /buffer move. In a channel, type: | You can move buffers (chat windows) with /buffer move. In a channel, type: | ||
/buffer move <num> | |||
(where <num> is any number you want). That channel is now accessible at Alt+<num> | (where <num> is any number you want). That channel is now accessible at Alt+<num> | ||
| Line 62: | Line 59: | ||
For example, I am currently connected to irc.redbrick.dcu.ie and to irc.starchat.net. If I hit Ctrl-x I can switch to StarChat, and change my nickname there without it affecting Redbrick's IRC. | For example, I am currently connected to irc.redbrick.dcu.ie and to irc.starchat.net. If I hit Ctrl-x I can switch to StarChat, and change my nickname there without it affecting Redbrick's IRC. | ||
== Mobile == | |||
weechat has a mobile app you can get from the [https://play.google.com/store/apps/details?id=com.ubergeek42.WeechatAndroid google play store] or from the [https://github.com/ubergeek42/weechat-android github]. | |||
Before we set up the app we need to go too weechat on the terminal and type in: | |||
/relay add weechat 1337 (choose your own port) | |||
then we need to set the password | |||
/set relay.network.password "your-secret-password" | |||
now on the Phone launch the app and in settings | |||
In connection settings | |||
Relay host: localhost | |||
Relay Port: 1337 (choose your own port) | |||
Relay password: your-secret-password | |||
Connect type: SSH tunnel | |||
then in SSH Tunnel settings | |||
SSH host: redbrick.dcu.ie | |||
SSH username: your username | |||
SSH port: 22 | |||
if you have an ssh key add the route to the key on your phone in SSH Private key file and put the passphrase in the SSH password/key passphrase box, if you dont just put your password in there | |||
== Special commands == | == Special commands == | ||
| Line 79: | Line 96: | ||
'''Note:''' Watch out for caps lock if you're keybinding. If you bind Alt+y to a command, Alt+Y won't work (unless you bind that separately). If you find your binds aren't working, check your caps. | '''Note:''' Watch out for caps lock if you're keybinding. If you bind Alt+y to a command, Alt+Y won't work (unless you bind that separately). If you find your binds aren't working, check your caps. | ||
== Triggers == | |||
=== Spell Checker | Triggers are the swiss army knife of weechat. They can replace a '''lot''' of scripts, and we're still finding things to turn into trigger | ||
=== Turn any line with "nsfw" in it bright red === | |||
/trigger addreplace nsfw modifier weechat_print "${tg_notify} && ${tg_message_nocolor} =~ .*nsfw.*" "/(.*)/${tg_prefix}\t${color:red}!NSFW! ${tg_message}" | |||
=== Make urls underlined and blue === | |||
/trigger addreplace url_color modifier "weechat_print" "${tg_tags} !~ irc_quit" ";[a-z]+://\S+;${color:32}${color:underline}${re:0}${color:-underline}${color:reset};" "" | |||
===Strip items such as time from screen on smaller screens === | |||
/trigger addreplace resize_small_timestamp signal signal_sigwinch "${info:term_width} < 200" "" "/set weechat.look.buffer_time_format \"\"" | |||
===add items such as time from screen on bigger screens === | |||
/trigger addreplace resize_big_timestamp signal signal_sigwinch "${info:term_width} >=200" "" "/set weechat.look.buffer_time_format %H:%M:%S " | |||
===Redact messages from specific users=== | |||
Helps keep better track of the conversation than if others are replying to messages you can't see. This example replaces messages from user1 and user2 with "[REDACTED]" | |||
/trigger addreplace shut_up modifier weechat_print "${tg_tags} =~ ,irc_privmsg, && ${tg_tags} =~ ,nick_(user1|user2|user3)," "/.*/${tg_prefix}\t${color:238}[REDACTED]" | |||
==Conditions== | |||
Conditions can be used to customize weechat depending on certain variables | |||
===Turn off nicklist on small windows=== | |||
/set weechat.bar.nicklist.conditions "${nicklist} && (${window.win_width} > 100 || ${buffer.full_name} == irc.bitlbee.&bitlbee)" | |||
===Hide buffer list on small terminals=== | |||
/set weechat.bar.buffers.conditions "${info:term_width} > 100" | |||
===Turn off status on nonactive windows === | |||
/set weechat.bar.status.conditions "${active}" | |||
== Spell Checker == | |||
Weechat uses a handy aspell plugin to check your spelling. To enable it, either use iset or use | Weechat uses a handy aspell plugin to check your spelling. To enable it, either use iset or use | ||
/set aspell.check.enabled on | |||
Aspell has a few settings which you may find useful | Aspell has a few settings which you may find useful | ||
/set aspell.check.real_time on | |||
/set aspell.check.word_min_length 2 | |||
/set aspell.check.default_dict "en" | |||
/set aspell.check.suggestions 3 | |||
Or alternatively if you use iset, search for aspell | Or alternatively if you use iset, search for aspell | ||
The aspell plugin can also offer suggestions as of 0.4.0 and it can be added as an item to your status bar. The item should be added to weechat.bar.status.items. For instance: | The aspell plugin can also offer suggestions as of 0.4.0 and it can be added as an item to your status bar. The item should be added to weechat.bar.status.items. For instance: | ||
/set weechat.bar.status.items "time |,buffer_number+:buffer_name+(buffer_modes)+ |,buffer_nicklist_count |,hotlist |,[aspell_suggest] | |||
edits