dot

packages and services management
Log | Files | Refs | README

commit 76569dc4fe0b9f84fcec34387e08c24d5ce112e5
parent 9e779605df83fbb7924ae64c28e7069494f35ef0
Author: Josuah Demangeon <mail@josuah.net>
Date:   Sat, 29 Apr 2017 09:49:33 +0200

Wired.  Layer 06

Diffstat:
Dbin/ii-server | 22----------------------
Mbin/io-url | 25++++++++++++++++++++++---
Murl | 10++++------
3 files changed, 26 insertions(+), 31 deletions(-)

diff --git a/bin/ii-server b/bin/ii-server @@ -1,22 +0,0 @@ -# run ii as a daemon - -IRC="${IRC:-$HOME/var/irc}" - -stty -echo; printf 'password: '; read PASS; stty sane; printf '\n' - -alias ii="nohup ii -i '$IRC' -k '$PASS' -f '$NAME'" - -ii -s irc.cyberia.is -e 6697 & -[ -p "$IRC/irc.cyberia.is/in" ] && cat << . >> "$IRC/irc.cyberia.is/in" -/join #cyberia -. - -ii -s unix.chat -e 6697 & -[ -p "$IRC/irc.cyberia.is/in" ] && cat << . >> "$IRC/irc.cyberia.is/in" -/join #unix -. - -ii -s irc.freenode.net -e 6697 & -[ -p "$IRC/irc.cyberia.is/in" ] && cat << . >> "$IRC/irc.cyberia.is/in" -/join #2f30 #openbsd -. diff --git a/bin/io-url b/bin/io-url @@ -1,5 +1,24 @@ -# open a link from $CONFIG/url in $BROWSER +# open a link from $CONFIG/url appropritately -"${BROWSER:-chromium}" & # So that calling browser again open a new tab +url="$(iomenu -s -p 'url' < "$ETC/url")" +name="$(printf %s "$url" | sed 's|/|!|g')" +[ "$SSH_TTY" ] && e='^\' || e='^Z' -iomenu -s -p 'url' < "$CONFIG/url" | xargs "${BROWSER:-chromium}" +case "$url" in +( http://* | https://* ) + exec ${BROWSER:-chromium} "$url" & + ;; +( ssh://* ) + ABDUCO="$name" exec abduco -e "$e" -A "$name" \ + ssh "$url" + ;; +( gopher://* ) + ABDUCO="$name" exec abduco -e "$e" -A "$name" \ + rlwrap cgo "$url" + ;; +( irc://* ) + ABDUCO="$name" exec abduco -e "$e" -A "$name" \ + ii -i "$HOME/var/irc" -e 6697 -n "$NICK" -f "$NAME" \ + -s "${url#irc://}" + ;; +esac diff --git a/url b/url @@ -18,12 +18,10 @@ http://mixtape.moe http://thecontext.net # IRC channels -irc://irc.freenode.net#2f30 -irc://irc.freenode.net##c -irc://irc.freenode.net#!/bin/sh -irc://irc.oftc.net#suckless -irc://unix.chat:6697#unix -irc://irc.cyberia.is:6697#unix +irc://irc.freenode.net +irc://irc.oftc.net +irc://unix.chat +irc://irc.cyberia.is # Plain text text http://lainzine.neocities.org/txt-releases/lainzine-3.txt