diff options
92 files changed, 2503 insertions, 1024 deletions
diff --git a/.Xdefaults b/.Xdefaults new file mode 100644 index 0000000..c0aecc0 --- /dev/null +++ b/.Xdefaults @@ -0,0 +1,81 @@ +! -*- mode: conf-xdefaults; mode: rainbow -*- +! - color scheme +*.background: #000000 +*.foreground: #ff9800 +! black +*.color0: #0c181c +*.color8: #2e3436 +! red +*.color1: #800000 +*.color9: #c89490 +! green +*.color2: #337733 +*.color10: #5ec95e +! yellow +*.color3: #eac435 +*.color11: #ffff77 +! blue +*.color4: #295874 +*.color12: RoyalBlue +! purple +*.color5: #585ca8 +*.color13: #9b859d +! cyan +*.color6: #287373 +*.color14: #53a5a5 +! white +*.color7: #808080 +*.color15: #ececec + +*.internalBorder: 0 + +! General +urxvt*loginShell: true +urxvt*scrollBar: false +urxvt*secondaryScroll: true +urxvt*saveLines: 65535 +urxvt*cursorBlink: false +urxvt*cursorUnderline: true +urxvt*urgentOnBell: true +urxvt*termName: rxvt-256color + +! Extensions +urxvt*perl-lib: /usr/lib/urxvt/perl/ +urxvt*perl-ext-common: default,matcher,searchable-scrollback +urxvt*urlLauncher: firefox +urxvt*matcher.button: 1 + +! Appearance +urxvt.font: -misc-tamsyn-medium-r-normal-*-17-*-*-*-*-*-iso8859-* +urxvt.boldFont: -misc-tamsyn-bold-r-normal-*-17-*-*-*-*-*-iso8859-* +urxvt.transparent: true + +xterm*faceName: -misc-tamsyn-medium-r-normal-*-17-*-*-*-*-*-iso8859-* + +!xft settings +Xft.antialias: true +Xft.rgba: rgb +Xft.hinting: true +Xft.hintstyle: hintslight + +! Emacs settings +Emacs*menuBar: off +Emacs*toolbar: off +Emacs*useXIM: off + +xfontsel.sampleText: \ +static void print_sample_message(XWindow *win) {\n\ + win.label->text = "Sample text 0123456789"\n\ +} + +xfontsel.sampleText16: \ +static void print_sample_message(XWindow *win) {\n\ + win.label->text = "Sample text 0123456789"\n\ +} + +xfontsel.sampleTextUCS: \ +static void print_sample_message(XWindow *win) {\n\ + win.label->text = "Sample text 0123456789"\n\ +} + +*.font: -misc-tamsyn-medium-r-normal-*-17-*-*-*-*-*-iso8859-* diff --git a/.Xmodmap b/.Xmodmap new file mode 100644 index 0000000..d605780 --- /dev/null +++ b/.Xmodmap @@ -0,0 +1,11 @@ +pointer = 3 2 1 + +! +! Swap Caps_Lock and Control_L +! +remove Lock = Caps_Lock +remove Control = Control_L +keysym Control_L = Caps_Lock +keysym Caps_Lock = Control_L +add Lock = Caps_Lock +add Control = Control_L diff --git a/.config/fish/config.fish b/.config/fish/config.fish new file mode 100755 index 0000000..247daad --- /dev/null +++ b/.config/fish/config.fish @@ -0,0 +1,85 @@ +#! /usr/bin/fish + +function fish_prompt -d "Write out the prompt" + set last_status $status + set current_directory (prompt_pwd) + set git_branch (git branch --contains HEAD 2>/dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/') + set pac_cnt (cat /var/cache/pacman/updates.cnt) + set aur_cnt (cat /var/cache/pacman/aur.cnt) + set cnormal (set_color white) + + echo -n $cnormal + + if test $pac_cnt -gt 0 -o $aur_cnt -gt 0 + printf '%s%d%s/%s%d%s:' (set_color cyan) $pac_cnt $cnormal (set_color cyan) $aur_cnt $cnormal + end + + printf '%s%s%s' (set_color magenta) (hostname|cut -d . -f 1) $cnormal + + if test -n "$current_directory" + printf ':%s%s%s' (set_color $fish_color_cwd) $current_directory $cnormal + end + + if test -n "$git_branch" + printf '@%s%s%s' (set_color yellow) $git_branch $cnormal + end + + if test $last_status -eq 0 + printf '%s%s' (set_color --bold green) + else + printf '%s%s' (set_color --bold red) + end + + printf '>%s ' (set_color normal) +end + +function cower + /usr/bin/cower --color=always --target=$HOME/var/aur $argv +end + +function grep + /bin/grep --color=always $argv +end + +function less + /bin/less -FXRS $argv +end + +function ls + /bin/ls -F --color=always $argv +end + +function mysql + /usr/bin/mysql --pager $argv +end + +function slrn + set -x NNTPSERVER 'news.gmane.org' + /usr/bin/slrn $argv +end + +function shutdown + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Stop +end + +function reboot + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Restart +end + +function engage + play -n -c1 synth whitenoise band -n 100 20 band -n 50 20 gain +25 fade h 1 864000 1 +end + +function lscompmod -d "List kernel modules used by hardware" + lspci -mvk | awk '/^Module/ {print $2}' | sort -u +end + +set -x PAGER 'less -FXRS' +set -x BROWSER firefox +set -x EDITOR 'emacs -nw' diff --git a/.config/herbstluftwm/autostart b/.config/herbstluftwm/autostart new file mode 100755 index 0000000..d93a60a --- /dev/null +++ b/.config/herbstluftwm/autostart @@ -0,0 +1,123 @@ +#!/usr/bin/guile +!# + +(define (hc command) + (system (string-append "herbstclient " command))) + +(define (keybind modkey key command) + (display (string-append "keybind " modkey "-" key " " command "\n")) + (hc (string-append "keybind " modkey "-" key " " command))) + +(define (mousebind modkey button command) + (hc (string-append "mousebind " modkey "-" button " " command))) + +(define (add-tag name) + (hc (string-append "add " name))) + +(define (set variable value) + (hc (string-append "set " variable " " value))) + +(define (unrule) + (hc "unrule -F")) + +(define (rule spec) + (hc (string-append "rule " spec))) + +(define modkey "Mod4") + +(define (create-tag name) + (add-tag name) + (keybind modkey name (string-append "use " name)) + (keybind modkey + (string-append "Shift-" name) + (string-append "move " name))) + +(define (dmenu-command fn nb nf) + (string-append "dmenu_run -fn '" fn "' -nb '" nb "' -nf '" nf "'")) + +(define (set-layout layout) + (display (string-append "set_layout " layout "\n")) + (hc (string-append "set_layout " layout))) + +;; colors +(set "frame_border_active_color" "\\#2e3436") +(set "frame_border_normal_color" "\\#0c191c") +(set "frame_bg_normal_color" "\\#2e3436") +(set "frame_bg_active_color" "\\#0c191c") +(set "frame_border_width" "0") +(set "window_border_width" "2") +(set "window_border_normal_color" "\\#0c191c") +(set "window_border_active_color" "\\#800000") + +;; other settings +(set "default_frame_layout" "2") +(set-layout "max") + +;; keybindings +(keybind modkey "Mod1-q" "quit") +(keybind modkey "Mod1-r" "reload") +(keybind modkey "Shift-Mod1-c" "close") +(keybind modkey "Return" "spawn urxvt") +(keybind modkey "r" + (string-append + "spawn " + (dmenu-command + "-misc-tamsyn-medium-r-normal-*-14-*-*-*-*-*-iso8859-*" + "#252a2b" "#eeeeec"))) +(keybind "Control" "Mod1-l" "spawn i3lock -c 000000") +(keybind modkey "t" "spawn ~/bin/hlwm/capture-todo") +(keybind modkey "Shift-t" "spawn ~/bin/hlwm/show-todo") + +;; tags +(hc "rename default q") +(for-each create-tag '("q" "w" "e" "a" "s" "d" "z" "x" "c")) + +;; layout +(hc "remove_monitor 1") +(hc "move_monitor 0 1680x1050+0+0") +(hc "add_monitor 1280x1024+1680+0 w") + +;; layouting +(keybind modkey "Shift-r" "remove") +(keybind modkey "space" "cycle_layout 1") +(keybind modkey "u" "split vertical 0.5") +(keybind modkey "o" "split horizontal 0.5") +(keybind modkey "f" "floating toggle") +(keybind modkey "Shift-f" "fullscreen toggle") +(keybind modkey "p" "pseudotile toggle") + +;; resizing +(define resizestep "0.05") +(keybind modkey "Control-h" (string-append "resize left +" resizestep)) +(keybind modkey "Control-j" (string-append "resize down +" resizestep)) +(keybind modkey "Control-k" (string-append "resize up +" resizestep)) +(keybind modkey "Control-l" (string-append "resize right +" resizestep)) + +;; mouse +(mousebind modkey "Button1" "move") +(mousebind modkey "Button2" "resize") +(mousebind modkey "Button3" "zoom") + +;; focus +(keybind modkey "BackSpace" "cycle_monitor") +(keybind modkey "Tab" "cycle_all +1") +(keybind modkey "Shift-Tab" "cycle_all -1") +(keybind modkey "Mod1-c" "cycle") +(keybind modkey "h" "focus left") +(keybind modkey "j" "focus down") +(keybind modkey "k" "focus up") +(keybind modkey "l" "focus right") +(keybind modkey "Shift-h" "shift left") +(keybind modkey "Shift-j" "shift down") +(keybind modkey "Shift-k" "shift up") +(keybind modkey "Shift-l" "shift right") + +;; rules +(unrule) +(rule "focus=on") ; normally do not focus new clients +(rule "windowtype=_NET_WM_WINDOW_TYPE_DIALOG focus=on pseudotile=on") +(rule "class=Xephyr pseudotile=on") + +;; Show panel + +(system "~/.config/herbstluftwm/panel.sh &") diff --git a/.config/herbstluftwm/panel.sh b/.config/herbstluftwm/panel.sh new file mode 100755 index 0000000..c955a0c --- /dev/null +++ b/.config/herbstluftwm/panel.sh @@ -0,0 +1,96 @@ +#!/bin/bash + +monitor=${1:-0} +geometry=( $(herbstclient monitor_rect "$monitor") ) +if [ -z "$geometry" ] ;then + echo "Invalid monitor $monitor" + exit 1 +fi +# geometry has the format: WxH+X+Y +x=${geometry[0]} +y=${geometry[1]} +width=${geometry[2]} +height=16 +font="-misc-tamsyn-medium-r-normal-*-14-*-*-*-*-*-iso8859-*" +fgcolor='#eeeeec' +bgcolor='#252a2b' +hintcolor="#0c191c" + +function uniq_linebuffered() { + awk '$0 != l { print ; l=$0 ; fflush(); }' "$@" +} + +herbstclient pad $monitor $height +{ + # events: + #mpc idleloop player & + while true ; do + date +'date ^fg($fgcolor)%H:%M^fg(#909090), %Y-%m-^fg($fgcolor)%d' + sleep 1 || break + done > >(uniq_linebuffered) & + childpid=$! + herbstclient --idle + kill $childpid +} 2> /dev/null | { + TAGS=( $(herbstclient tag_status $monitor) ) + date="" + while true ; do + bordercolor="#26221C" + separator="^fg(#141414)^ro(1x$height)^fg()" + # draw tags + echo -n "$separator" + for i in "${TAGS[@]}" ; do + case ${i:0:1} in + '#') + echo -n "^bg(#0c191c)^fg(#eeeeec)" + ;; + '+') + echo -n "^bg(#2e3436)^fg(#555753)" + ;; + ':') + echo -n "^bg(#2e3436)^fg($fgcolor)" + ;; + '!') + echo -n "^bg(#a40000)^fg(#edd400)" + ;; + *) + echo -n "^bg()^fg()" + ;; + esac + echo -n " ${i:1} " + echo -n "$separator" + done + echo -n "^bg()^p(_CENTER)" + # small adjustments + nfmail=`ls ~/documents/mail/ninthfloor/INBOX/new/ | wc -l` + gmail=`ls ~/documents/mail/gmail/INBOX/new/ | wc -l` + archmail=`ls ~/documents/mail/arch/INBOX/new/ | wc -l` + aethonmail=`ls ~/documents/mail/aethon/INBOX/new/ | wc -l` + right="$separator 9f: $nfmail $separator gmail: $gmail $separator arch: $archmail $separator aethon: $aethonmail $separator^bg($hintcolor) $date $separator" + right_text_only=$(echo -n "$right"|sed 's.\^[^(]*([^)]*)..g') + # get width of right aligned text.. and add some space.. + width=$(textwidth "$font" "$right_text_only ") + echo -n "^p(_RIGHT)^p(-$width)$right" + echo + # wait for next event + read line || break + cmd=( $line ) + # find out event origin + case "${cmd[0]}" in + tag*) + #echo "reseting tags" >&2 + TAGS=( $(herbstclient tag_status $monitor) ) + ;; + date) + #echo "reseting date" >&2 + date="${cmd[@]:1}" + ;; + quit_panel) + exit + ;; + #player) + # ;; + esac + done +} 2> /dev/null | dzen2 -w $width -x $x -y $y -fn "$font" -h $height \ + -ta l -bg "$bgcolor" -fg "$fgcolor" diff --git a/.config/newsbeuter/.gitignore b/.config/newsbeuter/.gitignore new file mode 100644 index 0000000..8afd898 --- /dev/null +++ b/.config/newsbeuter/.gitignore @@ -0,0 +1,3 @@ +cache.* +credentials +history.* diff --git a/.config/newsbeuter/config b/.config/newsbeuter/config new file mode 100644 index 0000000..acb8715 --- /dev/null +++ b/.config/newsbeuter/config @@ -0,0 +1,27 @@ +auto-reload yes +browser "$BROWSER" +confirm-exit yes +feedlist-format "%-35t %?d?- %-35d&? %> %u" +max-items 500 +notify-program notify-send +notify-beep yes +reload-threads 3 +reload-time 60 +show-read-feeds no +show-read-articles no +articlelist-format "%-4i %f %t" +feedlist-title-format "%N %V %> %u feeds with new articles" +articlelist-title-format "%T" +article-sort-order date-desc +html-renderer "w3m -dump -T text/HTML -cols 80" +text-width 80 + +# colors +color listfocus black green bold +color info white red + +# highlight +highlight article "^(Feed|Title|Author|Link|Date):.*" green default bold + +# keys +bind-key i prev-dialog diff --git a/.config/newsbeuter/urls b/.config/newsbeuter/urls new file mode 100644 index 0000000..bf48bea --- /dev/null +++ b/.config/newsbeuter/urls @@ -0,0 +1,124 @@ +# -*- mode: conf; mode: outline-minor -*- + +#-----[ Followed projects ]------------------------------------------- +https://github.com/ryuslash.private.atom?token=7362ca0604736cd92b5441949e8c9cd4 +http://gitorious.org/~ryuslash/watchlist.atom + +#-----[ Blogs ]------------------------------------------------------- +http://julien.danjou.info/blog/index.xml blogs +http://kakaroto.homelinux.net/feed/ blogs +http://awhan.wordpress.com/feed/ blogs +http://beej.us/blog/feed/ blogs +http://torvalds-family.blogspot.com/feeds/posts/default blogs +http://emacs.wordpress.com/feed/ blogs +http://feedproxy.google.com/SaferCode blogs +http://blog.gitorious.org/feed/ blogs +http://dieter.plaetinck.be/index.rss blogs + +#-----[ CVS Changes ]------------------------------------------------- +http://git.naquadah.org/?p=naquadah-theme.git;a=rss cvs +#http://git.naquadah.org/?p=rainbow.git;a=rss cvs +http://code.google.com/feeds/p/autopair/svnchanges/basic cvs +http://code.google.com/feeds/p/go/hgchanges/basic cvs +http://git.cs.fau.de/?p=re06huxa/herbstluftwm;a=atom cvs +https://github.com/diaspora/diaspora/commits/master.atom cvs +https://github.com/knopwob/dunst/commits/master.atom cvs + +#-----[ Programming ]------------------------------------------------- +http://www.reddit.com/r/cpp/.rss devel +http://services.devx.com/outgoing/devxfeed.xml devel +http://www.dzone.com/feed/frontpage/rss.xml devel +http://www.reddit.com/r/ExpertProgramming/.rss devel +http://www.reddit.com/r/programming/.rss devel +http://steve-yegge.blogspot.com/feeds/posts/default devel +http://www.reddit.com/r/systems/.rss devel +http://www.reddit.com/r/coding/.rss devel +http://www.reddit.com/r/git/.rss devel +http://www.reddit.com/r/C_Programming/.rss devel +http://feeds.feedburner.com/FalloutTutorials devel +http://www.devarticles.com/rss.xml devel +http://www.script-tutorials.com/feed/rss/ +http://news.ycombinator.com/rss + +#-----[ Linux and FLOSS ]--------------------------------------------- +http://www.reddit.com/r/commandline/.rss linux +http://www.desktoplinux.com/backend/headlines.rss linux +http://distrowatch.com/news/dw.xml linux +http://www.howtoforge.com/node/feed linux +http://www.ibm.com/developerworks/views/linux/rss/libraryview.jsp?type_by=Articles linux +http://www.ibm.com/developerworks/views/linux/rss/libraryview.jsp?type_by=Tutorials linux +http://feeds.feedburner.com/LinuxMagazine linux +http://www.linuxprogrammingblog.com/rss.xml linux +http://linuxtoday.com/backend/biglt.rss linux +http://www.linux.com/rss/feeds.php linux +http://www.linuxinsider.com/perl/syndication/rssfull.pl linux +http://lwn.net/headlines/newrss linux +http://blogs.zdnet.com/open-source/wp-rss2.php linux +http://ostatic.com/blog/feed linux +http://www.reddit.com/r/linux/.rss linux +http://www.theopenforce.com/atom.xml linux +http://www.ubuntugeek.com/feed/ linux +http://www.warpedsystems.sk.ca/backend/index.xml linux +http://www.reddit.com/r/archlinux/.rss linux +http://www.reddit.com/r/linuxquestions/.rss linux +http://www.echolinux.com/rss +http://www.tuxradar.com/rss + +#-----[ Emacs ]------------------------------------------------------- +http://wordpress.com/tag/emacs/feed/ emacs +http://www.reddit.com/r/emacs/.rss emacs +http://planet.emacsen.org/atom.xml emacs +http://emacsblog.org/feed/ emacs +http://www.emacswiki.org/emacs?action=rss emacs + +#-----[ N900 ]-------------------------------------------------------- +http://www.reddit.com/r/n900/.rss n900 +http://maemo.org/news/planet-maemo/rss.xml n900 +http://www.reddit.com/r/maemo/.rss n900 + +#-----[ iPhone ]------------------------------------------------------ +http://icodeblog.com/feed/ iphone +http://iphonesdkdev.blogspot.com/feeds/posts/default iphone +http://iphonedevelopertips.com/feed iphone + +#-----[ Other Software ]---------------------------------------------- +http://www.archlinux.org/feeds/news/ software +http://gitlog.wordpress.com/feed/ software +http://rollingrelease.com/?feed=rss software +http://sourceforge.net/export/rss2_keepsake.php?group_id=134378 software +http://valajournal.blogspot.com/feeds/posts/default software + +#-----[ Games ]------------------------------------------------------- +http://feeds.feedburner.com/qj/qjnet game + +#-----[ Funny ]------------------------------------------------------- +http://feeds.feedburner.com/ClientsFromHell funny +http://feeds.feedburner.com/VeryDemotivational funny + +#-----[ Comics ]------------------------------------------------------ +http://feeds.feedburner.com/AbstruseGoose comics +http://www.cad-comic.com/rss/rss.xml comics +http://feeds.dilbert.com/DilbertDailyStrip comics +http://feedproxy.google.com/uclick/garfield comics +http://feeds.feedburner.com/GeekAndPoke comics +http://feeds.feedburner.com/NotInventedHere comics +http://syndicated.livejournal.com/oglaf/data/rss comics +http://feeds.feedburner.com/omaketheater comics +http://www.penny-arcade.com/rss.xml comics +http://www.pvponline.com/rss/?section=article comics +http://www.questionablecontent.net/QCRSS.xml comics +http://feeds.feedburner.com/ScenesFromAMultiverse comics +http://www.vgcats.com/vgcats.rdf.xml comics +http://feeds2.feedburner.com/virtualshackles comics +http://xkcd.com/rss.xml comics +http://feeds.feedburner.com/maximumble?format=xml comics +http://bearmageddon.com/feed/ comics +http://feeds.feedburner.com/ProgsLife comics +http://www.rsspect.com/rss/asw.xml +http://pbfcomics.com/feed/feed.xml +http://feeds.feedburner.com/thisisindexed/SGWm + +#-----[ Misc ]-------------------------------------------------------- +http://wallbase.cc/rss misc +http://www.mailinator.com/rss.jsp?email=ryuslash misc +http://rss.slashdot.org/Slashdot/slashdot diff --git a/.conky_box.lua b/.conky_box.lua new file mode 100644 index 0000000..ef53427 --- /dev/null +++ b/.conky_box.lua @@ -0,0 +1,311 @@ +--[[BOX WIDGET v1.1 by Wlourf 27/01/2011 +This widget can drawn some boxes, even circles in your conky window +http://u-scripts.blogspot.com/2011/01/box-widget.html) + +Inspired by Background by londonali1010 (2009), thanks ;-) + +The parameters (all optionals) are : +x - x coordinate of top-left corner of the box, default = 0 = (top-left corner of conky window) +y - y coordinate of top-left corner of the box, default = 0 = (top-left corner of conky window) +w - width of the box, default = width of the conky window +h - height of the box, default = height of the conky window +corners - corners is a table for the four corners in this order : top-left, top-right,bottom-right, bottom-left + each corner is defined in a table with a shape and a radius, available shapes are : "curve","circle","line" + example for the same shapes for all corners: + { {"circle",10} } + example for first corner different from the three others + { {"circle",10}, {"circle",5} } + example for top corners differents from bottom corners + { {"circle",10}, {"circle",10}, {"line",0} } + default = { {"line",0} } i.e=no corner +operator - set the compositing operator (needs in the conkyrc : own_window_argb_visual yes) + see http://cairographics.org/operators/ + available operators are : + "clear","source","over","in","out","atop","dest","dest_over","dest_in","dest_out","dest_atop","xor","add","saturate" + default = "over" +border - if border>0, the script draws only the border, like a frame, default=0 +dash - if border>0 and dash>0, the border is draw with dashes, default=0 +skew_x - skew box around x axis, default = 0 +skew_y - skew box around y axis, default = 0 +scale_x - rescale the x axis, default=1, useful for drawing elipses ... +scale_y - rescale the x axis, default=1 +angle - angle of rotation of the box in degrees, default = 0 + i.e. a horizontal graph +rot_x - x point of rotation's axis, default = 0, + relative to top-left corner of the box, (not the conky window) +rot_y - y point of rotation's axis, default = 0 + relative to top-left corner of the box, (not the conky window) +draw_me - if set to false, box is not drawn (default = true or 1) + it can be used with a conky string, if the string returns 1, the box is drawn : + example : "${if_empty ${wireless_essid wlan0}}${else}1$endif", + +linear_gradient - table with the coordinates of two points to define a linear gradient, + points are relative to top-left corner of the box, (not the conky window) + {x1,y1,x2,y2} +radial_gradient - table with the coordinates of two circle to define a radial gradient, + points are relative to top-left corner of the box, (not the conky window) + {x1,y1,r1,x2,y2,r2} (r=radius) +colour - table of colours, default = plain white {{1,0xFFFFFF,0.5}} + this table contains one or more tables with format {P,C,A} + P=position of gradient (0 = start of the gradient, 1= end of the gradient) + C=hexadecimal colour + A=alpha (opacity) of color (0=invisible,1=opacity 100%) + Examples : + for a plain color {{1,0x00FF00,0.5}} + for a gradient with two colours {{0,0x00FF00,0.5},{1,0x000033,1}} {x=80,y=150,w=20,h=20, + radial_gradient={20,20,0,20,20,20}, + colour={{0.5,0xFFFFFF,1},{1,0x000000,0}}, + or {{0.5,0x00FF00,1},{1,0x000033,1}} -with this one, gradient will start in the middle + for a gradient with three colours {{0,0x00FF00,0.5},{0.5,0x000033,1},{1,0x440033,1}} + and so on ... + + + +To call this script in Conky, use (assuming you have saved this script to ~/scripts/): + lua_load ~/scripts/box.lua + lua_draw_hook_pre main_box + +And leave one line blank or not after TEXT + +Changelog: ++ v1.0 -- Original release (19.12.2010) ++ v1.1 -- Adding parameters: operator, dash, angle, skew_x, skew_y, draw_me + corners are described in a table + +-- This program is free software; you can redistribute it and/or modify +-- it under the terms of the GNU General Public License as published by +-- the Free Software Foundation version 3 (GPLv3) +-- +-- This program is distributed in the hope that it will be useful, +-- but WITHOUT ANY WARRANTY; without even the implied warranty of +-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +-- GNU General Public License for more details. +-- +-- You should have received a copy of the GNU General Public License +-- along with this program; if not, write to the Free Software +-- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +-- MA 02110-1301, USA. + + +]] + + +require 'cairo' + +function conky_main_box() + + if conky_window==nil then return end + + ---------------------- PARAMETERS BEGIN HERE + local boxes_settings={ + { + x = conky_window.text_start_x - 10, + y = conky_window.text_start_y - 10, + w = conky_window.text_width + 20, + h = conky_window.text_height + 20, + colour = {{1,0x000000,0.4}}, + }, + } + + + ---------------------------- PARAMETERS END HERE + + local cs=cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height) + local cr=cairo_create(cs) + + if tonumber(conky_parse("$updates"))<5 then return end + for i in pairs(boxes_settings) do + draw_box (cr,boxes_settings[i]) + end + cairo_destroy(cr) + cairo_surface_destroy(cs) +end + + +function draw_box(cr,t) + + if t.draw_me == true then t.draw_me = nil end + if t.draw_me ~= nil and conky_parse(tostring(t.draw_me)) ~= "1" then return end + + local table_corners={"circle","curve","line"} + + local t_operators={ + clear = CAIRO_OPERATOR_CLEAR, + source = CAIRO_OPERATOR_SOURCE, + over = CAIRO_OPERATOR_OVER, + ["in"] = CAIRO_OPERATOR_IN, + out = CAIRO_OPERATOR_OUT, + atop = CAIRO_OPERATOR_ATOP, + dest = CAIRO_OPERATOR_DEST, + dest_over = CAIRO_OPERATOR_DEST_OVER, + dest_in = CAIRO_OPERATOR_DEST_IN, + dest_out = CAIRO_OPERATOR_DEST_OUT, + dest_atop = CAIRO_OPERATOR_DEST_ATOP, + xor = CAIRO_OPERATOR_XOR, + add = CAIRO_OPERATOR_ADD, + saturate = CAIRO_OPERATOR_SATURATE, + } + + function rgba_to_r_g_b_a(tc) + --tc={position,colour,alpha} + local colour = tc[2] + local alpha = tc[3] + return ((colour / 0x10000) % 0x100) / 255., ((colour / 0x100) % 0x100) / 255., (colour % 0x100) / 255., alpha + end + + function table.copy(t) + local t2 = {} + for k,v in pairs(t) do + t2[k] = {v[1],v[2]} + end + return t2 + end + + function draw_corner(num,t) + local shape=t[1] + local radius=t[2] + local x,y = t[3],t[4] + if shape=="line" then + if num == 1 then cairo_line_to(cr,radius,0) + elseif num == 2 then cairo_line_to(cr,x,radius) + elseif num == 3 then cairo_line_to(cr,x-radius,y) + elseif num == 4 then cairo_line_to(cr,0,y-radius) + end + end + if shape=="circle" then + local PI = math.pi + if num == 1 then cairo_arc(cr,radius,radius,radius,-PI,-PI/2) + elseif num == 2 then cairo_arc(cr,x-radius,y+radius,radius,-PI/2,0) + elseif num == 3 then cairo_arc(cr,x-radius,y-radius,radius,0,PI/2) + elseif num == 4 then cairo_arc(cr,radius,y-radius,radius,PI/2,-PI) + end + end + if shape=="curve" then + if num == 1 then cairo_curve_to(cr,0,radius ,0,0 ,radius,0) + elseif num == 2 then cairo_curve_to(cr,x-radius,0, x,y, x,radius) + elseif num == 3 then cairo_curve_to(cr,x,y-radius, x,y, x-radius,y) + elseif num == 4 then cairo_curve_to(cr,radius,y, x,y, 0,y-radius) + end + end + end + + --check values and set default values + if t.x == nil then t.x = 0 end + if t.y == nil then t.y = 0 end + if t.w == nil then t.w = conky_window.width end + if t.h == nil then t.h = conky_window.height end + if t.radius == nil then t.radius = 0 end + if t.border == nil then t.border = 0 end + if t.colour==nil then t.colour={{1,0xFFFFFF,0.5}} end + if t.linear_gradient ~= nil then + if #t.linear_gradient ~= 4 then + t.linear_gradient = {t.x,t.y,t.width,t.height} + end + end + if t.angle==nil then t.angle = 0 end + + if t.skew_x == nil then t.skew_x=0 end + if t.skew_y == nil then t.skew_y=0 end + if t.scale_x==nil then t.scale_x=1 end + if t.scale_y==nil then t.scale_y=1 end + if t.rot_x == nil then t.rot_x=0 end + if t.rot_y == nil then t.rot_y=0 end + + if t.operator == nil then t.operator = "over" end + if (t_operators[t.operator]) == nil then + print ("wrong operator :",t.operator) + t.operator = "over" + end + + if t.radial_gradient ~= nil then + if #t.radial_gradient ~= 6 then + t.radial_gradient = {t.x,t.y,0, t.x,t.y, t.width} + end + end + + for i=1, #t.colour do + if #t.colour[i]~=3 then + print ("error in color table") + t.colour[i]={1,0xFFFFFF,1} + end + end + + if t.corners == nil then t.corners={ {"line",0} } end + local t_corners = {} + local t_corners = table.copy(t.corners) + --don't use t_corners=t.corners otherwise t.corners is altered + + --complete the t_corners table if needed + for i=#t_corners+1,4 do + t_corners[i]=t_corners[#t_corners] + local flag=false + for j,v in pairs(table_corners) do flag=flag or (t_corners[i][1]==v) end + if not flag then print ("error in corners table :",t_corners[i][1]);t_corners[i][1]="curve" end + end + + --this way : + -- t_corners[1][4]=x + -- t_corners[2][3]=y + --doesn't work + t_corners[1]={t_corners[1][1],t_corners[1][2],0,0} + t_corners[2]={t_corners[2][1],t_corners[2][2],t.w,0} + t_corners[3]={t_corners[3][1],t_corners[3][2],t.w,t.h} + t_corners[4]={t_corners[4][1],t_corners[4][2],0,t.h} + + t.no_gradient = (t.linear_gradient == nil ) and (t.radial_gradient == nil ) + + cairo_save(cr) + cairo_translate(cr, t.x, t.y) + if t.rot_x~=0 or t.rot_y~=0 or t.angle~=0 then + cairo_translate(cr,t.rot_x,t.rot_y) + cairo_rotate(cr,t.angle*math.pi/180) + cairo_translate(cr,-t.rot_x,-t.rot_y) + end + if t.scale_x~=1 or t.scale_y~=1 or t.skew_x~=0 or t.skew_y~=0 then + local matrix0 = cairo_matrix_t:create() + tolua.takeownership(matrix0) + cairo_matrix_init (matrix0, t.scale_x,math.pi*t.skew_y/180 , math.pi*t.skew_x/180 ,t.scale_y,0,0) + cairo_transform(cr,matrix0) + end + + local tc=t_corners + cairo_move_to(cr,tc[1][2],0) + cairo_line_to(cr,t.w-tc[2][2],0) + draw_corner(2,tc[2]) + cairo_line_to(cr,t.w,t.h-tc[3][2]) + draw_corner(3,tc[3]) + cairo_line_to(cr,tc[4][2],t.h) + draw_corner(4,tc[4]) + cairo_line_to(cr,0,tc[1][2]) + draw_corner(1,tc[1]) + + if t.no_gradient then + cairo_set_source_rgba(cr,rgba_to_r_g_b_a(t.colour[1])) + else + if t.linear_gradient ~= nil then + pat = cairo_pattern_create_linear (t.linear_gradient[1],t.linear_gradient[2],t.linear_gradient[3],t.linear_gradient[4]) + elseif t.radial_gradient ~= nil then + pat = cairo_pattern_create_radial (t.radial_gradient[1],t.radial_gradient[2],t.radial_gradient[3], + t.radial_gradient[4],t.radial_gradient[5],t.radial_gradient[6]) + end + for i=1, #t.colour do + cairo_pattern_add_color_stop_rgba (pat, t.colour[i][1], rgba_to_r_g_b_a(t.colour[i])) + end + cairo_set_source (cr, pat) + cairo_pattern_destroy(pat) + end + + cairo_set_operator(cr,t_operators[t.operator]) + + if t.border>0 then + cairo_close_path(cr) + if t.dash ~= nil then cairo_set_dash(cr, t.dash, 1, 0.0) end + cairo_set_line_width(cr,t.border) + cairo_stroke(cr) + else + cairo_fill(cr) + end + + cairo_restore(cr) +end + diff --git a/.conkyrc b/.conkyrc new file mode 100644 index 0000000..3f1f87a --- /dev/null +++ b/.conkyrc @@ -0,0 +1,73 @@ +background yes +use_xft yes +xftfont tamsyn:pixelsize=14 +!xftalpha 0.1 +update_interval 2.0 +total_run_times 0 +double_buffer yes +minimum_size 250 5 +maximum_width 400 +draw_shades no +draw_outline no +draw_borders no +draw_graph_borders no +default_color gray +default_shade_color red +default_outline_color green +alignment top_right +gap_x 10 +gap_y 42 +no_buffers yes +uppercase no +cpu_avg_samples 2 +net_avg_samples 1 +override_utf8_locale no +use_spacer yes +lua_load ~/.conkybox.lua +lua_draw_hook_pre conky_main_box + +TEXT +${font Arial:size=20}${color Tan1}${alignc}GNU${color RoyalBlue}LINUX$font +$alignc${color Tan1}$nodename + +${font Arial:bold:size=10}${color Tan1}SYSTEM ${color RoyalBlue}${voffset -2}${hr 2} +$font${color SlateGray}$sysname $kernel $alignr $machine +Intel Pentium 4 $alignr${freq_g cpu0}Ghz +Uptime $alignr${uptime} +File System $alignr${fs_type} + +$if_mpd_playing${font Arial:bold:size=10}${color Tan1}MUSIC ${color RoyalBlue}${voffset -2}${hr 2} +$font$alignc${color SlateGray}$mpd_title +$alignc$mpd_artist +$alignc$mpd_album +$mpd_bar + +$endif${font Arial:bold:size=10}${color Tan1}USAGE ${color RoyalBlue}${voffset -2}${hr 2} +$font${color SlateGray}CPU1 $alignr${cpu cpu1}% ${cpubar cpu1 7,170} +$font${color SlateGray}CPU2 $alignr${cpu cpu2}% ${cpubar cpu2 7,170} +$font${color SlateGray}MEM $alignr${memperc}% ${membar 7,170} +$font${color SlateGray}SWAP $alignr${swapperc}% ${swapbar 7, 170} + +${font Arial:bold:size=10}${color Tan1}HDD ${color RoyalBlue}${voffset -2}${hr 2} +${font}${color SlateGray}Write: $alignr$diskio_write +Read: $alignr$diskio_read + +${color SlateGray}/ $alignc$fs_used / $fs_size $alignr${fs_free_perc}% +${fs_bar} +$font${color SlateGray}/boot $alignc${fs_used /boot} / ${fs_size /boot} $alignr${fs_free_perc /boot}% +${fs_bar /boot} +$font${color SlateGray}/home $alignc${fs_used /home} / ${fs_size /home} $alignr${fs_free_perc /home}% +${fs_bar /home} + +${font Arial:bold:size=10}${color Tan1}TOP PROCESS ${color RoyalBlue}${voffset -2}${hr 2} +${color SlateGray}$font${top name 1}${alignr}${top cpu 1}% + +${font Arial:bold:size=10}${color Tan2}NETWORK ${color RoyalBlue}${voffset -2}${hr 2} +$font${color SlateGray}Active interface:$alignr$gw_iface +$font${color SlateGray}Active IP address: $alignr$addr + +Download speed: $alignr${downspeed eth0} +Upload speed: $alignr${upspeed eth0} + +Downloaded: $alignr${totaldown eth0} +Uploaded: $alignr${totalup eth0} diff --git a/.emacs.d b/.emacs.d new file mode 160000 +Subproject a05c538da1cdf97591a10806988112c5d8c5dd2 diff --git a/.fonts.conf b/.fonts.conf new file mode 100644 index 0000000..6204d1f --- /dev/null +++ b/.fonts.conf @@ -0,0 +1,34 @@ +<?xml version="1.0"?> +<!DOCTYPE fontconfig SYSTEM "fonts.dtd"> +<fontconfig> + + <!-- settings go here --> + <match target="pattern"> + <edit name="antialias" mode="assign"> + <bool>true</bool> + </edit> + + <edit name="hinting" mode="assign"> + <bool>true</bool> + </edit> + + <edit name="hintstyle" mode="assign"> + <const>hintslight</const> + </edit> + + <edit name="rgba" mode="assign"> + <const>rgb</const> + </edit> + + <edit name="autohint" mode="assign"> + <bool>true</bool> + </edit> + </match> + + <match target="font"> + <edit name="lcdfilter" mode="assign"> + <const>lcddefault</const> + </edit> + </match> + +</fontconfig> diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 0000000..04e9618 --- /dev/null +++ b/.gitconfig @@ -0,0 +1,19 @@ +[user] + name = Tom Willemsen + email = tom@ryuslash.org +[core] + editor = emacs -nw +[color] + ui = auto +[alias] + st = status -s + unadd = reset HEAD + lschanged = diff --name-only + history = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative +[sendemail] + smtpencryption = tls + smtpserver = smtp.gmail.com + smtpuser = ryuslash@gmail.com + smtpserverport = 587 +[merge] + tool = emerge @@ -1,4 +1,13 @@ -*.pyc -local_settings.py -.toudou -test.db +*~ +*session.* +*\#* +*.dat +local_* +feeds +fetchlog +log +*.log +*.elc +auto-save-list +xhtml-loader.rnc +.commitmsg diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..ddeb067 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,6 @@ +[submodule ".zsh/syntax-highlighting"] + path = .zsh/syntax-highlighting + url = git://github.com/zsh-users/zsh-syntax-highlighting +[submodule ".emacs.d"] + path = .emacs.d + url = git@gitorious.org:ryuslash/dotemacs.git diff --git a/.mutt/.gitignore b/.mutt/.gitignore new file mode 100644 index 0000000..ce8da72 --- /dev/null +++ b/.mutt/.gitignore @@ -0,0 +1,4 @@ +cache +temp +alias +certificates diff --git a/.mutt/aethon.muttrc b/.mutt/aethon.muttrc new file mode 100644 index 0000000..259098a --- /dev/null +++ b/.mutt/aethon.muttrc @@ -0,0 +1,14 @@ +### +# aethon.nl specific options +### + +set from = "thomas@aethon.nl" +set smtp_url = "smtp://thomas@aethon.nl@smtp.gmail.com:587/" +set mbox = "+aethon/INBOX" +set signature = "~/documents/work/aethon/signature.txt" +set postponed = "+aethon/drafts" +unset record + +macro index E "<change-folder>+aethon/archive<enter><limit>~B " "search everything" +macro index D "<save-message>+aethon/trash<enter>" "move message to the trash" +macro index S "<save-message>+aethon/spam<enter>" "mark message as spam" diff --git a/.mutt/arch.muttrc b/.mutt/arch.muttrc new file mode 100644 index 0000000..36b260b --- /dev/null +++ b/.mutt/arch.muttrc @@ -0,0 +1,14 @@ +### +# archlinux.us specific options +### + +set from = "tom.willemsen@archlinux.us" +set smtp_url = "smtp://tom.willemsen@archlinux.us@smtp.gmail.com:587/" +set mbox = "+arch/INBOX" +set postponed = "+arch/drafts" +unset record +unset signature + +macro index E "<change-folder>+arch/archive<enter><limit>~B " "search everything" +macro index D "<save-message>+arch/trash<enter>" "move message to the trash" +macro index S "<save-message>+arch/spam<enter>" "mark message as spam" diff --git a/.mutt/colors.muttrc b/.mutt/colors.muttrc new file mode 100644 index 0000000..75e5239 --- /dev/null +++ b/.mutt/colors.muttrc @@ -0,0 +1,65 @@ +### +# mutt colors file +### + +# set default +color normal default default + +# main colors +# element foreground background +color status color7 color1 +color indicator color0 color2 +color tree color5 default +color error brightcolor1 default +color message color3 default + +# uncolor certain messages +uncolor index "~P" +uncolor index "~N ~u" +uncolor index "~N !~u" +uncolor index "~T" +uncolor index "~D" + +# and recolor them appropriately +color index color3 default "~P" +color index color2 default "~u" +color index brightcolor2 default "~N ~u" # new ML mail +color index brightcolor3 default "~N !~u" # new non-ML mail +color index brightcolor5 default "~T" +color index color1 default "~D" + +# set up the headers +color header brightcolor2 default "^from:" +color header brightcolor2 default "^to:" +color header brightcolor2 default "^cc:" +color header brightcolor2 default "^date:" +color header brightcolor2 default "^subject:" + +# message bodies +color attachment color3 default +color search color1 color0 +color signature color5 default +color tilde color4 default + +# urls +color body brightcolor4 default "(^|<| )mailto:[^ ]+@[^ ]( |>|$)" +color body brightcolor4 default "(^|<| )(http|https|ftp|file|telnet|news|finger)://[^ ]+( |>|$)" + +# smileys +color body brightcolor5 default "(^| )+(|[<>|])[8;:](|[^ ])[)(/|DOPS]( |$)+" +color body brightcolor5 default "(^| )+[)(/|DOPS](|[^ ])[8;:](|[<>|])( |$)+" + +# *bold*, _underline_ and /italic/ +color body brightcolor6 default "(^| )\\*[^*]+\\*( |$)" +color body brightcolor6 default "(^| )_[^_]+_( |$)" +color body brightcolor6 default "(^| )/[^/]+/( |$)" + +# quote blocks +color quoted brightcolor0 default +color quoted1 brightcolor1 default +color quoted2 brightcolor2 default +color quoted3 brightcolor3 default +color quoted4 brightcolor4 default +color quoted5 brightcolor5 default +color quoted6 brightcolor6 default +color quoted7 brightdefault default diff --git a/.mutt/gmail.muttrc b/.mutt/gmail.muttrc new file mode 100644 index 0000000..80c9178 --- /dev/null +++ b/.mutt/gmail.muttrc @@ -0,0 +1,14 @@ +### +# gmail specific option +### + +set from = "ryuslash@gmail.com" +set smtp_url = "smtp://ryuslash@gmail.com@smtp.gmail.com:587/" +set mbox = "+gmail/INBOX" +set postponed = "+gmail/drafts" +unset record +unset signature + +macro index E "<change-folder>+gmail/archive<enter><limit>~B " "search everything" +macro index D "<save-message>+gmail/trash<enter>" "move message to the trash" +macro index S "<save-message>+gmail/spam<enter>" "mark message as spam" diff --git a/.mutt/iactor.muttrc b/.mutt/iactor.muttrc new file mode 100644 index 0000000..f090b5f --- /dev/null +++ b/.mutt/iactor.muttrc @@ -0,0 +1,13 @@ +### +# iactor specific options +### + +set from = "tom@iactor.nl" +set smtp_url = "mail.iactor.nl:2525" +set mbox = "+iactor/INBOX" +set record = "+iactor/Sent" +set postponed = "+iactor/Drafts" +unset signature + +macro index E "<change-folder>+iactor/INBOX<enter><limit>~B " "search everything" +macro index D "<save-message>+iactor/Trash<enter>" "move message to the trash" diff --git a/.mutt/macros b/.mutt/macros new file mode 100644 index 0000000..3f6ec6b --- /dev/null +++ b/.mutt/macros @@ -0,0 +1 @@ +macro pager \cb <pipe-entry>'urlview'<enter> 'Follow links with urlview' diff --git a/.mutt/mailcap b/.mutt/mailcap new file mode 100644 index 0000000..fba56f6 --- /dev/null +++ b/.mutt/mailcap @@ -0,0 +1,6 @@ +text/html; w3m -dump -T text/html -cols 80 %s; nametemplate=%s.html; copiousoutput +application/vnd.openxmlformats-officedocument.wordprocessingml.document; libreoffice %s +application/vnd.ms-excel; libreoffice %s +image/jpeg; feh %s +image/png; feh %s +application/pdf; gv %s diff --git a/.mutt/muttrc b/.mutt/muttrc new file mode 100644 index 0000000..249ad5f --- /dev/null +++ b/.mutt/muttrc @@ -0,0 +1,122 @@ +### +# ~/.muttrc +### + +# directories and commands +set alias_file = ~/.mutt/alias # alias file +set header_cache = ~/.mutt/cache/headers # where to store headers +set message_cachedir = ~/.mutt/cache/bodies # where to store bodies +set certificate_file = ~/.mutt/certificates # where to store certs +set mailcap_path = ~/.mutt/mailcap # entries for filetypes +set tmpdir = ~/.mutt/temp # where to keep temp files +set editor = "emacs -nw" + +# main options +set mbox_type = Maildir # mailbox type +set folder = ~/documents/mail # mailbox location +set spoolfile = "+ninthfloor/INBOX" # ninthfloor is the default inbox +set timeout = 3 # idle time before scanning +set mail_check = 0 # minimum time between scans +set sort_alias = alias # sort alias file by alias +set reverse_alias # show names from alias file in index +unset move # gmail does that +set delete # don't ask, just do +unset confirmappend # don't ask, just do! +set quit # don't ask, just do!! +unset mark_old # read/new is good enough for me +set beep_new # bell on new mails +set pipe_decode # strip headers and eval mimes when piping +set thorough_search # strip headers and eval mimes before searching +set ssl_force_tls = yes + +# index options +set sort = threads # like gmail +set sort_aux = last-date-received # not like gmail +set uncollapse_jump # don't collapse on an unread message +#set sort_re # thread based on regex + +# pager options +set pager_index_lines = 10 # number of index lines to + # show +set pager_context = 5 # number of context lines + # to show +set pager_stop # don't go to next message + # automatically +set menu_scroll # scroll in menus +set smart_wrap # don't split words +set tilde # show tildes like in vim +unset markers # no ugly plus signs +auto_view text/html # view html automatically +alternative_order text/plain text/enriched text/html # save html for last +set quote_regexp = "^( {0,4}[>|:#%]| {0,4}[a-z0-9]+[>|]+)+| {4}" + +# formats +set status_format = "-%r %f [Msgs:%?M?%M/?%m%?n? New:%n?%?o? Old:%o?%?d? Del:%d?%?F? Flag:%F?%?t? Tag:%t?%?p? Post:%p?%?b? Inc:%b?%?l? %l?] (%s/%S) %> (%P) " +set date_format = "%d %b %H:%M" +set index_format = "%3C %Z %D [%-12.12L] %s" +set alias_format = "%4n %t %-20a %r" + +# composing mail +set realname = "Tom Willemsen" # who am I? +set envelope_from # which from? +set sig_dashes # dashes before my sig... sweet +set edit_headers # show headers when composing +set fast_reply # skip to compose when replying +set askcc # ask for CC: +set fcc_attach # save attachments with the body +unset mime_forward # forward attachments as part fo body +set forward_format = "Fwd: %s" # format for subject when forwarding +set forward_decode # decode when forwarding +set attribution = "On %d, %n wrote:" # set the attribution +set reply_to # reply to Reply to: field +set reverse_name # reply as whomever it was to +set include # include message in replies +set forward_quote # include message inforwards + +# headers to show +ignore * # ignore all headers +unignore from: to: cc: date: subject: # show only these +hdr_order from: to: cc: date: subject: # and in this order + +# boxes +mailboxes +arch/INBOX #+arch/archive +arch/sent +arch/drafts +arch/spam +arch/trash +mailboxes +gmail/INBOX #+gmail/archive +gmail/sent +gmail/drafts +gmail/spam +gmail/trash +mailboxes +iactor/INBOX #+iactor/INBOX.Admin +iactor/INBOX.Important +iactor/INBOX.Intern +iactor/INBOX.Taken +iactor/Sent +iactor/Drafts +iactor/Trash +mailboxes +aethon/INBOX +mailboxes +ninthfloor/INBOX +mailboxes +ryuslash.org/INBOX + +# always sourced +source $alias_file # required for functionality +source ~/.mutt/colors.muttrc # source colors file +source ~/.mutt/ninthfloor.muttrc # source arch as default + +# account specific sources +folder-hook arch/* source ~/.mutt/arch.muttrc +folder-hook gmail/* source ~/.mutt/gmail.muttrc +folder-hook iactor/* source ~/.mutt/iactor.muttrc +folder-hook aethon/* source ~/.mutt/aethon.muttrc +folder-hook ninthfloor/* source ~/.mutt/ninthfloor.muttrc +folder-hook ryuslash.org/* source ~/.mutt/ryuslash.org.muttrc + +# abook +set query_command = "abook --mutt-query '%s'" + +# macros +macro index I "<change-folder>!<enter>" "go to Inbox" +macro index Z "<shell-escape>/usr/bin/offlineimap -q -o<enter>" "sync IMAP" +macro generic,index,pager \ca "<shell-escape>abook<return>" "launch abook" +macro index,pager A "<pipe-message>abook --add-email<return>" "add the sender address to abook" +macro generic,index,pager <ESC>1 "<change-folder>=ninthfloor/INBOX<return>" "Show ninthfloor inbox" +macro generic,index,pager <ESC>2 "<change-folder>=gmail/INBOX<return>" "Show gmail inbox" +macro generic,index,pager <ESC>3 "<change-folder>=arch/INBOX<return>" "Show arch inbox" +macro generic,index,pager <ESC>4 "<change-folder>=aethon/INBOX<return>" "Show aethon inbox" +macro generic,index,pager <ESC>5 "<change-folder>=ryuslash.org/INBOX<return>" "Show ryuslash.org inbox" +macro generic,index,pager <ESC>6 "<change-folder>=iactor/INBOX<return>" "Show iactor inbox" + +# key bindings +bind pager \177 previous-line # default didn't want to work anymore +#bind generic i what-key + +# mailing lists +subscribe dev@suckless.org diff --git a/.mutt/ninthfloor.muttrc b/.mutt/ninthfloor.muttrc new file mode 100644 index 0000000..16a3358 --- /dev/null +++ b/.mutt/ninthfloor.muttrc @@ -0,0 +1,13 @@ +### +# ninthfloor specific options +### + +set from = "ryuslash@ninthfloor.org" +set smtp_url = "smtp://ryuslash@mail.ninthfloor.org:587" +set mbox = "+ninthfloor/INBOX" +set record = "+ninthfloor/Sent" +set postponed = "+ninthfloor/Drafts" +unset signature + +macro index E "<change-folder>+ninthfloor/INBOX<enter><limit>~B " "search everything" +macro index D "<save-message>+ninthfloor/Trash<enter>" "move message to the trash" diff --git a/.mutt/ryuslash.org.muttrc b/.mutt/ryuslash.org.muttrc new file mode 100644 index 0000000..315aa9d --- /dev/null +++ b/.mutt/ryuslash.org.muttrc @@ -0,0 +1,13 @@ +### +# ryuslash.org specific options +### + +set from = "tom@ryuslash.org" +set smtp_url = "smtp://tom@ryuslash.org@smtp.alwaysdata.com:587" +set mbox = "+ryuslash.org/INBOX" +set record = "+ryuslash.org/Sent" +set postponed = "+ryuslash.org/Drafts" +unset signature + +macro index E "<change-folder>+ryuslash.org/INBOX<enter><limit>~B " "search everything" +macro index D "<save-message>+ninthfloor/Trash<enter>" "move message to the trash" diff --git a/.ncmpcpp/config b/.ncmpcpp/config new file mode 100644 index 0000000..dff7507 --- /dev/null +++ b/.ncmpcpp/config @@ -0,0 +1,91 @@ +# Playlist +autocenter_mode = "yes" +centered_cursor = "yes" +now_playing_prefix = "$b" +now_playing_suffix = "$/b" +playlist_display_mode = "classic" # (classic/columns) +song_list_format = "{$8%d%n}|{ $8%n}$9 | {$3%a$9 - }{$4%t$9} {$R$5[%b]$9}" + +# Bars +display_bitrate = "no" +progressbar_look = ">> " +song_status_format = "$0%t$9 {$1by$9 $0%a$9} {$1from$9 $0%b$9}{$1,$9 $0%y$9}" +titles_visibility = "no" + +# Browser +browser_display_mode = "classic" # (classic/columns) +browser_playlist_prefix = "$2plist >$9 " + +# Colors +active_column_color = "yellow" +color1 = "default" +color2 = "green" +discard_colors_if_item_is_selected = "yes" +header_visibikity = "yes" +header_window_color = "magenta" +main_window_color = "default" +main_window_highlight_color = "default" +progressbar_color = "red" +state_flags_color = "yellow" +state_line_color = "black" +statusbar_color = "magenta" +statusbar_visibility = "yes" +volume_color = "cyan" + +# Others +allow_physical_directories_deletion = "yes" +allow_physical_files_deletion = "yes" +fancy_scrolling = "yes" +mpd_music_dir = "/mnt/music/mp3" +search_engine_display_mode = "columns" # (classic/columns) +user_interface = "alternative" # (classic/alternative) + +#active_window_border = "red" +#alternative_header_first_line_format = "$b$1$aqqu$/a$9 {%t}|{%f} $1$atqq$/a$9$/b" +#alternative_header_second_line_format = "{{$4$b%a$/b$9}{ - $7%b$9}{ ($4%y$9)}}|{%D}" +#alternative_ui_separator_color = "black" +#ask_before_clearing_main_playlist = "no" +#block_search_constraints_change_if_items_found = "yes" +#clock_display_seconds = "no" +#colors_enabled = "yes" +#cyclic_scrolling = "no" +#default_find_mode = "wrapped" (wrapped/normal) +#default_place_to_search_in = "database" (database/playlist) +#default_space_mode = "add" (add/select) +#default_tag_editor_left_col = "albums" (albums/dirs) +#default_tag_editor_pattern = "%n - %t" +#display_remaining_time = "no" +#display_screens_numbers_on_start = "yes" +#empty_tag_color = "cyan" +#empty_tag_marker = "<empty>" +#enable_window_title = "yes" +#execute_on_song_change = "" +#external_editor = "" +#follow_now_playing_lyrics = "no" +#header_text_scrolling = "yes" +#ignore_leading_the = "no" +#incremental_seeking = "yes" +#jump_to_now_playing_song_at_start = "yes" +#lines_scrolled = "2" +#lyrics_database = "1" +#media_library_left_column = "a" (possible values: a,y,g,c,p, legend above) +#message_delay_time = "4" +#mouse_support = "yes" +#mpd_connection_timeout = "5" +#mpd_crossfade_time = "3" +#mpd_host = "localhost" +#mpd_port = "6600" +#ncmpc_like_songs_adding = "no" (enabled - add/remove, disabled - always add) +#playlist_disable_highlight_delay = "5" +#playlist_show_remaining_time = "no" +#regular_expressions = "basic" (basic/extended) +#seek_time = "1" +#selected_item_prefix = "$6" +#selected_item_suffix = "$9" +#show_hidden_files_in_local_browser = "no" +#song_columns_list_format = "(10f)[green]{lr} (25)[cyan]{aE} (40)[]{t} (30)[red]{b}" +#song_library_format = "{%n - }{%t}|{%f}" +#song_window_title_format = "{%a - }{%t}|{%f}" +#tag_editor_album_format = "{(%y) }%b" +#use_console_editor = "no" (set to yes, if your editor is console app) +#window_border_color = "green" diff --git a/.offlineimap.py b/.offlineimap.py new file mode 100644 index 0000000..a63709b --- /dev/null +++ b/.offlineimap.py @@ -0,0 +1,9 @@ +def getuser(host): + import netrc + mynet = netrc.netrc() + return mynet.authenticators(host)[0] + +def getpassword(host): + import netrc + mynet = netrc.netrc() + return mynet.authenticators(host)[2] diff --git a/.offlineimaprc b/.offlineimaprc new file mode 100644 index 0000000..caabb9e --- /dev/null +++ b/.offlineimaprc @@ -0,0 +1,97 @@ +[general] +# NOTE: cronjob calls the quiet UI with -u +ui = TTYUI +accounts = ryuslash.org,gmail,arch,aethon,iactor,ninthfloor +pythonfile = ~/.offlineimap.py + +[Account arch] +localrepository = arch-local +remoterepository = arch-remote + +[Account gmail] +localrepository = gmail-local +remoterepository = gmail-remote + +[Account iactor] +localrepository = iactor-local +remoterepository = iactor-remote + +[Account aethon] +localrepository = aethon-local +remoterepository = aethon-remote + +[Account ninthfloor] +localrepository = ninthfloor-local +remoterepository = ninthfloor-remote + +[Account ryuslash.org] +localrepository = ryuslash.org-local +remoterepository = ryuslash.org-remote + +[Repository arch-local] +type = Maildir +localfolders = ~/documents/mail/arch + +[Repository gmail-local] +type = Maildir +localfolders = ~/documents/mail/gmail + +[Repository iactor-local] +type = Maildir +localfolders = ~/documents/mail/iactor + +[Repository aethon-local] +type = Maildir +localfolders = ~/documents/mail/aethon + +[Repository ninthfloor-local] +type = Maildir +localfolders = ~/documents/mail/ninthfloor + +[Repository ryuslash.org-local] +type = Maildir +localfolders = ~/documents/mail/ryuslash.org + +[Repository arch-remote] +type = Gmail +remoteusereval = getuser("imap.google.com-arch") +remotepasseval = getpassword("imap.google.com-arch") +realdelete = no + +nametrans = lambda folder: re.sub('.*Spam$', 'spam', re.sub('.*Drafts$', 'drafts', re.sub('.*Sent Mail$', 'sent', re.sub('.*Starred$', 'flagged', re.sub('.*Trash$', 'trash', re.sub('.*All Mail$', 'archive', folder)))))) + +[Repository gmail-remote] +type = Gmail +remoteusereval = getuser("imap.google.com") +remotepasseval = getpassword("imap.google.com") +realdelete = no + +nametrans = lambda folder: re.sub('.*Spam$', 'spam', re.sub('.*Drafts$', 'drafts', re.sub('.*Sent Mail$', 'sent', re.sub('.*Starred$', 'flagged', re.sub('.*Trash$', 'trash', re.sub('.*All Mail$', 'archive', folder)))))) + +[Repository iactor-remote] +type = IMAP +remotehost = mail.iactor.nl +remoteusereval = getuser("mail.iactor.nl") +remotepasseval = getpassword("mail.iactor.nl") + +[Repository aethon-remote] +type = Gmail +remoteusereval = getuser("imap.google.com-aethon") +remotepasseval = getpassword("imap.google.com-aethon") +realdelete = no + +nametrans = lambda folder: re.sub('.*Spam$', 'spam', re.sub('.*Drafts$', 'drafts', re.sub('.*Sent Mail$', 'sent', re.sub('.*Starred$', 'flagged', re.sub('.*Trash$', 'trash', re.sub('.*All Mail$', 'archive', folder)))))) + +[Repository ninthfloor-remote] +type = IMAP +remotehost = ninthfloor.org +remoteusereval = getuser("ninthfloor.org") +remotepasseval = getpassword("ninthfloor.org") + +[Repository ryuslash.org-remote] +type = IMAP +remotehost = imap.alwaysdata.com +remoteusereval = getuser("imap.alwaysdata.com") +remotepasseval = getpassword("imap.alwaysdata.com") + +# vim: ft=cfg tw=0 @@ -0,0 +1,49 @@ +nnrpaccess news.eternal-september.org slash "" +server news.eternal-september.org .local/share/slrn/newsrc/eternal-september +server news.gmane.org .local/share/slrn/newsrc/gmane + +color unread_subject "white" "default" "bold" + +color article "lightgray" "default" +color author "magenta" "default" +color boldtext "brightblue" "default" "bold" +color box "black" "white" +color cursor "brightgreen" "default" +color date "lightgray" "default" +color description "lightgray" "default" +color error "red" "default" "blink" +color frame "yellow" "blue" +color from_myself "brightmagenta" "default" "bold" +color group "lightgray" "default" "bold" +color grouplens_display "lightgray" "default" +color header_name "green" "default" "bold" +color header_number "green" "default" +color headers "brightcyan" "default" +color neg_score "green" "default" +color pos_score "blue" "default" +color high_score "red" "default" "bold" +color italicstext "magenta" "default" "bold" +color menu "white" "red" +color menu_press "lightgray" "yellow" +color message "lightgray" "default" +color normal "default" "default" +color pgpsignature "lightgray" "default" +color quotes "red" "default" +color quotes1 "magenta" "default" +color quotes2 "brown" "default" +color quotes3 "brown" "default" +color quotes4 "brown" "default" +color quotes5 "brown" "default" +color quotes6 "brown" "default" +color quotes7 "brown" "default" +color response_char "green" "default" "bold" +color signature "red" "default" +color selection "yellow" "blue" "bold" +color status "white" "red" +color subject "lightgray" "default" +color thread_number "lightgray" "default" "bold" +color tilde "green" "default" "bold" +color tree "red" "default" "bold" +color underlinetext "cyan" "default" "underline" +color url "white" "default" "bold" +color verbatim "green" "default" diff --git a/.ssh/config b/.ssh/config new file mode 100644 index 0000000..c2db5de --- /dev/null +++ b/.ssh/config @@ -0,0 +1,18 @@ +ControlMaster auto +ControlPath /tmp/ssh_mux_%h_%p_%r +ControlPersist 10m + +Host 192.168.0.95 +Port 4511 + +Host pegas +Port 4511 + +Host 82.170.172.156 +Port 4511 + +Host anapnea.net +User ryuslash + +Host my.aethon.nl +User root diff --git a/.weechat/alias.conf b/.weechat/alias.conf new file mode 100644 index 0000000..dc8e9b3 --- /dev/null +++ b/.weechat/alias.conf @@ -0,0 +1,38 @@ +# +# alias.conf -- weechat v0.3.6 +# + +[cmd] +AAWAY = "allserv /away" +AME = "allchan /me" +AMSG = "allchan /msg *" +ANICK = "allserv /nick" +BYE = "quit" +C = "buffer clear" +CHAT = "dcc chat" +CL = "buffer clear" +CLOSE = "buffer close" +EXIT = "quit" +ident = "msg NickServ identify $*" +IG = "ignore" +J = "join" +K = "kick" +KB = "kickban" +LEAVE = "part" +M = "msg" +MUB = "unban *" +N = "names" +Q = "query" +REDRAW = "window refresh" +SAY = "msg *" +SIGNOFF = "quit" +T = "topic" +UB = "unban" +V = "command core version" +W = "who" +WC = "window merge" +WI = "whois" +WII = "whois $1 $1" +WW = "whowas" + +[completion] diff --git a/.weechat/irc.conf b/.weechat/irc.conf new file mode 100644 index 0000000..1e15734 --- /dev/null +++ b/.weechat/irc.conf @@ -0,0 +1,154 @@ +# +# irc.conf -- weechat v0.3.6 +# + +[look] +buffer_switch_autojoin = on +buffer_switch_join = on +color_nicks_in_names = off +color_nicks_in_nicklist = off +color_nicks_in_server_messages = on +color_pv_nick_like_channel = on +display_away = local +display_ctcp_blocked = on +display_ctcp_reply = on +display_ctcp_unknown = on +display_host_join = on +display_host_join_local = on +display_host_quit = on +display_old_topic = on +display_pv_away_once = on +display_pv_back = on +hide_nickserv_pwd = on +highlight_tags = "irc_privmsg,irc_notice" +item_away_message = on +item_channel_modes = on +item_channel_modes_hide_key = off +item_display_server = buffer_plugin +item_nick_modes = on +item_nick_prefix = on +msgbuffer_fallback = current +new_channel_position = none +new_pv_position = none +nick_color_force = "" +nick_color_stop_chars = "_|[" +nick_completion_smart = speakers +nick_prefix = "" +nick_suffix = "" +notice_as_pv = auto +notify_tags_ison = "notify_message" +notify_tags_whois = "notify_message" +part_closes_buffer = off +raw_messages = 256 +server_buffer = merge_with_core +smart_filter = on +smart_filter_delay = 5 +smart_filter_join = on +smart_filter_nick = on +smart_filter_quit = on +topic_strip_colors = off + +[color] +input_nick = lightcyan +item_away = yellow +item_channel_modes = default +item_lag_counting = default +item_lag_finished = yellow +message_join = green +message_quit = red +nick_prefix = green +nick_prefixes = "q:lightred;a:lightcyan;o:lightgreen;h:lightmagenta;v:yellow;*:lightblue" +nick_suffix = green +notice = green +reason_quit = default +topic_new = white +topic_old = darkgray + +[network] +autoreconnect_delay_growing = 2 +autoreconnect_delay_max = 1800 +colors_receive = on +colors_send = on +lag_check = 60 +lag_disconnect = 0 +lag_min_show = 500 +lag_refresh_interval = 1 +notify_check_ison = 1 +notify_check_whois = 5 +send_unknown_commands = off + +[msgbuffer] + +[ctcp] + +[ignore] + +[server_default] +addresses = "" +anti_flood_prio_high = 2 +anti_flood_prio_low = 2 +autoconnect = off +autojoin = "" +autoreconnect = on +autoreconnect_delay = 10 +autorejoin = off +autorejoin_delay = 30 +away_check = 0 +away_check_max_nicks = 25 +command = "" +command_delay = 0 +connection_timeout = 60 +default_msg_part = "WeeChat %v" +default_msg_quit = "WeeChat %v" +ipv6 = off +local_hostname = "" +nicks = "slash,slash1,slash2,slash3,slash4" +notify = "" +password = "" +proxy = "" +realname = "" +sasl_mechanism = plain +sasl_password = "" +sasl_timeout = 15 +sasl_username = "" +ssl = off +ssl_cert = "" +ssl_dhkey_size = 2048 +ssl_priorities = "NORMAL" +ssl_verify = on +username = "slash" + +[server] +freenode.addresses = "irc.freenode.net" +freenode.proxy +freenode.ipv6 +freenode.ssl +freenode.ssl_cert +freenode.ssl_priorities +freenode.ssl_dhkey_size +freenode.ssl_verify +freenode.password +freenode.sasl_mechanism +freenode.sasl_username +freenode.sasl_password +freenode.sasl_timeout +freenode.autoconnect = on +freenode.autoreconnect +freenode.autoreconnect_delay +freenode.nicks = "ryuslash" +freenode.username = "ryuslash" +freenode.realname +freenode.local_hostname +freenode.command +freenode.command_delay +freenode.autojoin +freenode.autorejoin +freenode.autorejoin_delay +freenode.connection_timeout +freenode.anti_flood_prio_high +freenode.anti_flood_prio_low +freenode.away_check +freenode.away_check_max_nicks +freenode.default_msg_part +freenode.default_msg_quit +freenode.notify diff --git a/.weechat/weechat.conf b/.weechat/weechat.conf new file mode 100644 index 0000000..60ae637 --- /dev/null +++ b/.weechat/weechat.conf @@ -0,0 +1,512 @@ +# +# weechat.conf -- weechat v0.3.6 +# + +[debug] + +[startup] +command_after_plugins = "" +command_before_plugins = "" +display_logo = on +display_version = on + +[look] +align_end_of_lines = message +bar_more_down = "++" +bar_more_left = "<<" +bar_more_right = ">>" +bar_more_up = "--" +buffer_notify_default = all +buffer_time_format = "%H:%M:%S" +color_basic_force_bold = off +color_inactive_buffer = off +color_inactive_message = on +color_inactive_prefix = on +color_inactive_prefix_buffer = on +color_inactive_time = off +color_inactive_window = off +color_pairs_auto_reset = 5 +color_real_white = off +command_chars = "" +confirm_quit = off +day_change = on +day_change_time_format = "%a, %d %b %Y" +eat_newline_glitch = off +highlight = "" +highlight_regex = "" +highlight_tags = "" +hotlist_add_buffer_if_away = on +hotlist_buffer_separator = ", " +hotlist_count_max = 2 +hotlist_count_min_msg = 2 +hotlist_names_count = 3 +hotlist_names_length = 0 +hotlist_names_level = 12 +hotlist_names_merged_buffers = off +hotlist_short_names = on +hotlist_sort = group_time_asc +hotlist_unique_numbers = on +input_cursor_scroll = 20 +input_share = none +input_share_overwrite = off +input_undo_max = 32 +item_buffer_filter = "*" +item_time_format = "%H:%M" +jump_current_to_previous_buffer = on +jump_previous_buffer_when_closing = on +mouse = off +mouse_timer_delay = 100 +nickmode = on +nickmode_empty = off +paste_max_lines = 3 +prefix_action = " *" +prefix_align = right +prefix_align_max = 0 +prefix_align_min = 0 +prefix_align_more = on +prefix_buffer_align = right +prefix_buffer_align_max = 0 +prefix_buffer_align_more = on +prefix_error = "=!=" +prefix_join = "-->" +prefix_network = "--" +prefix_quit = "<--" +prefix_suffix = "|" +read_marker = line +read_marker_always_show = off +read_marker_string = "- " +save_config_on_exit = on +save_layout_on_exit = none +scroll_amount = 3 +scroll_page_percent = 100 +search_text_not_found_alert = on +separator_horizontal = "-" +separator_vertical = "" +set_title = on +time_format = "%a, %d %b %Y %T" + +[palette] + +[color] +bar_more = lightmagenta +chat = default +chat_bg = default +chat_buffer = white +chat_channel = white +chat_delimiters = green +chat_highlight = yellow +chat_highlight_bg = magenta +chat_host = cyan +chat_inactive_buffer = darkgray +chat_inactive_window = darkgray +chat_nick = lightcyan +chat_nick_colors = "cyan,magenta,green,brown,lightblue,default,lightcyan,lightmagenta,lightgreen,blue" +chat_nick_other = cyan +chat_nick_self = white +chat_prefix_action = white +chat_prefix_buffer = brown +chat_prefix_buffer_inactive_buffer = darkgray +chat_prefix_error = yellow +chat_prefix_join = lightgreen +chat_prefix_more = lightmagenta +chat_prefix_network = magenta +chat_prefix_quit = lightred +chat_prefix_suffix = green +chat_read_marker = magenta +chat_read_marker_bg = default +chat_server = brown +chat_tags = red +chat_text_found = yellow +chat_text_found_bg = lightmagenta +chat_time = default +chat_time_delimiters = brown +chat_value = cyan +input_actions = lightgreen +input_text_not_found = red +nicklist_away = cyan +nicklist_group = green +nicklist_offline = blue +separator = blue +status_count_highlight = magenta +status_count_msg = brown +status_count_other = default +status_count_private = green +status_data_highlight = lightmagenta +status_data_msg = yellow +status_data_other = default +status_data_private = lightgreen +status_filter = green +status_more = yellow +status_name = white +status_name_ssl = lightgreen +status_number = yellow +status_time = default + +[completion] +default_template = "%(nicks)|%(irc_channels)" +nick_add_space = on +nick_completer = ":" +nick_first_only = off +nick_ignore_chars = "[]`_-^" +partial_completion_alert = on +partial_completion_command = off +partial_completion_command_arg = off +partial_completion_count = on +partial_completion_other = off + +[history] +display_default = 5 +max_commands = 100 +max_lines = 4096 +max_visited_buffers = 50 + +[proxy] + +[network] +gnutls_ca_file = "%h/ssl/CAs.pem" +gnutls_handshake_timeout = 30 + +[plugin] +autoload = "*" +debug = off +extension = ".so" +path = "%h/plugins" +save_config_on_unload = on + +[bar] +input.color_bg = default +input.color_delim = cyan +input.color_fg = default +input.conditions = "" +input.filling_left_right = vertical +input.filling_top_bottom = horizontal +input.hidden = off +input.items = "[input_prompt]+(away),[input_search],[input_paste],input_text" +input.position = bottom +input.priority = 1000 +input.separator = off +input.size = 1 +input.size_max = 0 +input.type = window +nicklist.color_bg = default +nicklist.color_delim = cyan +nicklist.color_fg = default +nicklist.conditions = "nicklist" +nicklist.filling_left_right = vertical +nicklist.filling_top_bottom = columns_vertical +nicklist.hidden = off +nicklist.items = "buffer_nicklist" +nicklist.position = right +nicklist.priority = 200 +nicklist.separator = on +nicklist.size = 0 +nicklist.size_max = 0 +nicklist.type = window +status.color_bg = red +status.color_delim = cyan +status.color_fg = default +status.conditions = "" +status.filling_left_right = vertical +status.filling_top_bottom = horizontal +status.hidden = off +status.items = "[time],[buffer_count],[buffer_plugin],buffer_number+:+buffer_name+{buffer_nicklist_count}+buffer_filter,[lag],[hotlist],completion,scroll" +status.position = bottom +status.priority = 500 +status.separator = off +status.size = 1 +status.size_max = 0 +status.type = window +title.color_bg = red +title.color_delim = cyan +title.color_fg = white +title.conditions = "" +title.filling_left_right = vertical +title.filling_top_bottom = horizontal +title.hidden = off +title.items = "buffer_title" +title.position = top +title.priority = 500 +title.separator = off +title.size = 1 +title.size_max = 0 +title.type = window + +[layout] + +[notify] + +[filter] + +[key] +ctrl-? = "/input delete_previous_char" +ctrl-A = "/input move_beginning_of_line" +ctrl-B = "/input move_previous_char" +ctrl-Cb = "/input insert \x02" +ctrl-Cc = "/input insert \x03" +ctrl-Ci = "/input insert \x1D" +ctrl-Co = "/input insert \x0F" +ctrl-Cr = "/input insert \x12" +ctrl-Cu = "/input insert \x15" +ctrl-D = "/input delete_next_char" +ctrl-E = "/input move_end_of_line" +ctrl-F = "/input move_next_char" +ctrl-H = "/input delete_previous_char" +ctrl-I = "/input complete_next" +ctrl-J = "/input return" +ctrl-K = "/input delete_end_of_line" +ctrl-L = "/window refresh" +ctrl-M = "/input return" +ctrl-N = "/buffer +1" +ctrl-P = "/buffer -1" +ctrl-R = "/input search_text" +ctrl-Sctrl-U = "/input set_unread" +ctrl-T = "/input transpose_chars" +ctrl-U = "/input delete_beginning_of_line" +ctrl-W = "/input delete_previous_word" +ctrl-X = "/input switch_active_buffer" +ctrl-Y = "/input clipboard_paste" +meta-meta2-1~ = "/window scroll_top" +meta-meta2-23~ = "/bar scroll nicklist * yb" +meta-meta2-24~ = "/bar scroll nicklist * ye" +meta-meta2-4~ = "/window scroll_bottom" +meta-meta2-5~ = "/window scroll_up" +meta-meta2-6~ = "/window scroll_down" +meta-meta2-7~ = "/window scroll_top" +meta-meta2-8~ = "/window scroll_bottom" +meta-meta2-A = "/buffer -1" +meta-meta2-B = "/buffer +1" +meta-meta2-C = "/buffer +1" +meta-meta2-D = "/buffer -1" +meta-0 = "/buffer *10" +meta-1 = "/buffer *1" +meta-2 = "/buffer *2" +meta-3 = "/buffer *3" +meta-4 = "/buffer *4" +meta-5 = "/buffer *5" +meta-6 = "/buffer *6" +meta-7 = "/buffer *7" +meta-8 = "/buffer *8" +meta-9 = "/buffer *9" +meta-< = "/input jump_previously_visited_buffer" +meta-= = "/filter toggle" +meta-> = "/input jump_next_visited_buffer" +meta-OA = "/input history_global_previous" +meta-OB = "/input history_global_next" +meta-OC = "/input move_next_word" +meta-OD = "/input move_previous_word" +meta-OF = "/input move_end_of_line" +meta-OH = "/input move_beginning_of_line" +meta-Oa = "/input history_global_previous" +meta-Ob = "/input history_global_next" +meta-Oc = "/input move_next_word" +meta-Od = "/input move_previous_word" +meta2-15~ = "/buffer -1" +meta2-17~ = "/buffer +1" +meta2-18~ = "/window -1" +meta2-19~ = "/window +1" +meta2-1;3A = "/buffer -1" +meta2-1;3B = "/buffer +1" +meta2-1;3C = "/buffer +1" +meta2-1;3D = "/buffer -1" +meta2-1;5A = "/input history_global_previous" +meta2-1;5B = "/input history_global_next" +meta2-1~ = "/input move_beginning_of_line" +meta2-20~ = "/bar scroll title * x-50%" +meta2-21~ = "/bar scroll title * x+50%" +meta2-23~ = "/bar scroll nicklist * y-100%" +meta2-24~ = "/bar scroll nicklist * y+100%" +meta2-3~ = "/input delete_next_char" +meta2-4~ = "/input move_end_of_line" +meta2-5;3~ = "/window scroll_up" +meta2-5~ = "/window page_up" +meta2-6;3~ = "/window scroll_down" +meta2-6~ = "/window page_down" +meta2-7~ = "/input move_beginning_of_line" +meta2-8~ = "/input move_end_of_line" +meta2-A = "/input history_previous" +meta2-B = "/input history_next" +meta2-C = "/input move_next_char" +meta2-D = "/input move_previous_char" +meta2-F = "/input move_end_of_line" +meta2-G = "/window page_down" +meta2-H = "/input move_beginning_of_line" +meta2-I = "/window page_up" +meta2-Z = "/input complete_previous" +meta-_ = "/input redo" +meta-a = "/input jump_smart" +meta-b = "/input move_previous_word" +meta-d = "/input delete_next_word" +meta-f = "/input move_next_word" +meta-h = "/input hotlist_clear" +meta-jmeta-l = "/input jump_last_buffer" +meta-jmeta-r = "/server raw" +meta-jmeta-s = "/server jump" +meta-j01 = "/buffer 1" +meta-j02 = "/buffer 2" +meta-j03 = "/buffer 3" +meta-j04 = "/buffer 4" +meta-j05 = "/buffer 5" +meta-j06 = "/buffer 6" +meta-j07 = "/buffer 7" +meta-j08 = "/buffer 8" +meta-j09 = "/buffer 9" +meta-j10 = "/buffer 10" +meta-j11 = "/buffer 11" +meta-j12 = "/buffer 12" +meta-j13 = "/buffer 13" +meta-j14 = "/buffer 14" +meta-j15 = "/buffer 15" +meta-j16 = "/buffer 16" +meta-j17 = "/buffer 17" +meta-j18 = "/buffer 18" +meta-j19 = "/buffer 19" +meta-j20 = "/buffer 20" +meta-j21 = "/buffer 21" +meta-j22 = "/buffer 22" +meta-j23 = "/buffer 23" +meta-j24 = "/buffer 24" +meta-j25 = "/buffer 25" +meta-j26 = "/buffer 26" +meta-j27 = "/buffer 27" +meta-j28 = "/buffer 28" +meta-j29 = "/buffer 29" +meta-j30 = "/buffer 30" +meta-j31 = "/buffer 31" +meta-j32 = "/buffer 32" +meta-j33 = "/buffer 33" +meta-j34 = "/buffer 34" +meta-j35 = "/buffer 35" +meta-j36 = "/buffer 36" +meta-j37 = "/buffer 37" +meta-j38 = "/buffer 38" +meta-j39 = "/buffer 39" +meta-j40 = "/buffer 40" +meta-j41 = "/buffer 41" +meta-j42 = "/buffer 42" +meta-j43 = "/buffer 43" +meta-j44 = "/buffer 44" +meta-j45 = "/buffer 45" +meta-j46 = "/buffer 46" +meta-j47 = "/buffer 47" +meta-j48 = "/buffer 48" +meta-j49 = "/buffer 49" +meta-j50 = "/buffer 50" +meta-j51 = "/buffer 51" +meta-j52 = "/buffer 52" +meta-j53 = "/buffer 53" +meta-j54 = "/buffer 54" +meta-j55 = "/buffer 55" +meta-j56 = "/buffer 56" +meta-j57 = "/buffer 57" +meta-j58 = "/buffer 58" +meta-j59 = "/buffer 59" +meta-j60 = "/buffer 60" +meta-j61 = "/buffer 61" +meta-j62 = "/buffer 62" +meta-j63 = "/buffer 63" +meta-j64 = "/buffer 64" +meta-j65 = "/buffer 65" +meta-j66 = "/buffer 66" +meta-j67 = "/buffer 67" +meta-j68 = "/buffer 68" +meta-j69 = "/buffer 69" +meta-j70 = "/buffer 70" +meta-j71 = "/buffer 71" +meta-j72 = "/buffer 72" +meta-j73 = "/buffer 73" +meta-j74 = "/buffer 74" +meta-j75 = "/buffer 75" +meta-j76 = "/buffer 76" +meta-j77 = "/buffer 77" +meta-j78 = "/buffer 78" +meta-j79 = "/buffer 79" +meta-j80 = "/buffer 80" +meta-j81 = "/buffer 81" +meta-j82 = "/buffer 82" +meta-j83 = "/buffer 83" +meta-j84 = "/buffer 84" +meta-j85 = "/buffer 85" +meta-j86 = "/buffer 86" +meta-j87 = "/buffer 87" +meta-j88 = "/buffer 88" +meta-j89 = "/buffer 89" +meta-j90 = "/buffer 90" +meta-j91 = "/buffer 91" +meta-j92 = "/buffer 92" +meta-j93 = "/buffer 93" +meta-j94 = "/buffer 94" +meta-j95 = "/buffer 95" +meta-j96 = "/buffer 96" +meta-j97 = "/buffer 97" +meta-j98 = "/buffer 98" +meta-j99 = "/buffer 99" +meta-k = "/input grab_key_command" +meta-n = "/window scroll_next_highlight" +meta-p = "/window scroll_previous_highlight" +meta-r = "/input delete_line" +meta-u = "/input scroll_unread" +meta-wmeta-meta2-A = "/window up" +meta-wmeta-meta2-B = "/window down" +meta-wmeta-meta2-C = "/window right" +meta-wmeta-meta2-D = "/window left" +meta-wmeta2-1;3A = "/window up" +meta-wmeta2-1;3B = "/window down" +meta-wmeta2-1;3C = "/window right" +meta-wmeta2-1;3D = "/window left" +meta-wmeta-b = "/window balance" +meta-wmeta-s = "/window swap" +meta-z = "/window zoom" +ctrl-_ = "/input undo" + +[key_search] +ctrl-J = "/input search_stop" +ctrl-M = "/input search_stop" +ctrl-R = "/input search_switch_case" +meta2-A = "/input search_previous" +meta2-B = "/input search_next" + +[key_cursor] +ctrl-J = "/cursor stop" +ctrl-M = "/cursor stop" +meta-meta2-A = "/cursor move area_up" +meta-meta2-B = "/cursor move area_down" +meta-meta2-C = "/cursor move area_right" +meta-meta2-D = "/cursor move area_left" +meta2-1;3A = "/cursor move area_up" +meta2-1;3B = "/cursor move area_down" +meta2-1;3C = "/cursor move area_right" +meta2-1;3D = "/cursor move area_left" +meta2-A = "/cursor move up" +meta2-B = "/cursor move down" +meta2-C = "/cursor move right" +meta2-D = "/cursor move left" +@item(buffer_nicklist):K = "/window ${_window_number};/kickban ${nick}" +@item(buffer_nicklist):b = "/window ${_window_number};/ban ${nick}" +@item(buffer_nicklist):k = "/window ${_window_number};/kick ${nick}" +@item(buffer_nicklist):q = "/window ${_window_number};/query ${nick};/cursor stop" +@item(buffer_nicklist):w = "/window ${_window_number};/whois ${nick}" +@chat:Q = "hsignal:chat_quote_time_prefix_message;/cursor stop" +@chat:m = "hsignal:chat_quote_message;/cursor stop" +@chat:q = "hsignal:chat_quote_prefix_message;/cursor stop" + +[key_mouse] +@bar(input):button2 = "/input grab_mouse_area" +@bar(nicklist):button1-gesture-down = "/bar scroll nicklist ${_window_number} +100%" +@bar(nicklist):button1-gesture-down-long = "/bar scroll nicklist ${_window_number} e" +@bar(nicklist):button1-gesture-up = "/bar scroll nicklist ${_window_number} -100%" +@bar(nicklist):button1-gesture-up-long = "/bar scroll nicklist ${_window_number} b" +@item(buffer_nicklist):button1 = "/window ${_window_number};/query ${nick}" +@item(buffer_nicklist):button1-gesture-left = "/window ${_window_number};/kick ${nick}" +@item(buffer_nicklist):button1-gesture-left-long = "/window ${_window_number};/kickban ${nick}" +@item(buffer_nicklist):button2 = "/window ${_window_number};/whois ${nick}" +@item(buffer_nicklist):button2-gesture-left = "/window ${_window_number};/ban ${nick}" +@bar:wheeldown = "/bar scroll ${_bar_name} ${_window_number} +20%" +@bar:wheelup = "/bar scroll ${_bar_name} ${_window_number} -20%" +@chat:button1 = "/window ${_window_number}" +@chat:button1-gesture-left = "/window ${_window_number};/buffer -1" +@chat:button1-gesture-left-long = "/window ${_window_number};/buffer 1" +@chat:button1-gesture-right = "/window ${_window_number};/buffer +1" +@chat:button1-gesture-right-long = "/window ${_window_number};/input jump_last_buffer" +@chat:wheeldown = "/window scroll_down -window ${_window_number}" +@chat:wheelup = "/window scroll_up -window ${_window_number}" +@*:button3 = "/cursor go ${_x},${_y}" diff --git a/.xinitrc b/.xinitrc new file mode 100644 index 0000000..7eedf1d --- /dev/null +++ b/.xinitrc @@ -0,0 +1,26 @@ +# -*- mode: shell-script -*- + +# -----[ Set background ]--------------------------------------------- +hsetroot -center ~/pictures/wallpapers/2960x1050/wallpaper-680196.jpg + +# -----[ Modify keys ]------------------------------------------------ +xmodmap ~/.Xmodmap + +# -----[ Start some programs ]---------------------------------------- +conky +numlockx & + +# mpdscribble +pidof mpdscribble >& /dev/null +if [ $? -ne 0 ] +then + mpdscribble & +fi + +# -----[ Start notifier ]--------------------------------------------- +/usr/bin/dunst \ + -fn "-misc-tamsyn-medium-r-normal-*-14-*-*-*-*-*-iso8859-*" \ + -nb "#252a2b" -nf "#eeeeec" & + +# -----[ Start session ]---------------------------------------------- +exec ck-launch-session /usr/bin/herbstluftwm 2>&1 > ~/.xsession_errors diff --git a/.zsh/.gitignore b/.zsh/.gitignore new file mode 100644 index 0000000..b9fd690 --- /dev/null +++ b/.zsh/.gitignore @@ -0,0 +1 @@ +histfile diff --git a/.zsh/functions/chpwd_show_todo b/.zsh/functions/chpwd_show_todo new file mode 100644 index 0000000..88ee853 --- /dev/null +++ b/.zsh/functions/chpwd_show_todo @@ -0,0 +1,7 @@ +# -*- mode: Shell-script -*- + +if [ -e ".toudou" ]; then + toudou +elif [ "$PWD" = "$HOME" ]; then + toudou list -g +fi diff --git a/.zsh/functions/chpwd_update_git_vars b/.zsh/functions/chpwd_update_git_vars new file mode 100755 index 0000000..0ef846a --- /dev/null +++ b/.zsh/functions/chpwd_update_git_vars @@ -0,0 +1,2 @@ +# -*- mode: shell-script -*- +update_current_git_vars diff --git a/.zsh/functions/precmd_update_git_vars b/.zsh/functions/precmd_update_git_vars new file mode 100755 index 0000000..172456a --- /dev/null +++ b/.zsh/functions/precmd_update_git_vars @@ -0,0 +1,6 @@ +# -*- mode: shell-script -*- + +if [ -n "$__EXECUTED_GIT_COMMAND" ]; then + update_current_git_vars + unset __EXECUTED_GIT_COMMAND +fi diff --git a/.zsh/functions/preexec_update_git_vars b/.zsh/functions/preexec_update_git_vars new file mode 100755 index 0000000..9d229a9 --- /dev/null +++ b/.zsh/functions/preexec_update_git_vars @@ -0,0 +1,6 @@ +# -*- mode: shell-script -*- +case "$1" in + git*) + __EXECUTED_GIT_COMMAND=1 + ;; +esac diff --git a/.zsh/functions/prompt_git_info b/.zsh/functions/prompt_git_info new file mode 100755 index 0000000..76d889a --- /dev/null +++ b/.zsh/functions/prompt_git_info @@ -0,0 +1,23 @@ +# -*- mode: shell-script -*- + +if [ -n "$__CURRENT_GIT_BRANCH" ]; then + local s="(" + s+="$__CURRENT_GIT_BRANCH" + case "$__CURRENT_GIT_BRANCH_STATUS" in + ahead) + s+="↑" + ;; + diverged) + s+="↕" + ;; + behind) + s+="↓" + ;; + esac + if [ -n "$__CURRENT_GIT_BRANCH_IS_DIRTY" ]; then + s+="⚡" + fi + s+=")" + + printf " %s%s" "%{${fg[yellow]}%}" $s +fi diff --git a/.zsh/functions/update_current_git_vars b/.zsh/functions/update_current_git_vars new file mode 100755 index 0000000..71f37e7 --- /dev/null +++ b/.zsh/functions/update_current_git_vars @@ -0,0 +1,30 @@ +# -*- mode: Shell-script -*- +unset __CURRENT_GIT_BRANCH +unset __CURRENT_GIT_BRANCH_STATUS +unset __CURRENT_GIT_BRANCH_IS_DIRTY + +local st="$(git status 2>/dev/null)" +if [[ -n "$st" ]]; then + local -a arr + arr=(${(f)st}) + + if [[ $arr[1] =~ 'Not currently on any branch.' ]]; then + __CURRENT_GIT_BRANCH='no-branch' + else + __CURRENT_GIT_BRANCH="${arr[1][(w)4]}" + fi + + if [[ $arr[2] =~ 'Your branch is' ]]; then + if [[ $arr[2] =~ 'ahead' ]]; then + __CURRENT_GIT_BRANCH_STATUS='ahead' + elif [[ $arr[2] =~ 'devirged' ]]; then + __CURRENT_GIT_BRANCH_STATUS='diverged' + else + __CURRENT_GIT_BRANCH_STATUS='behind' + fi + fi + + if [[ ! $st =~ 'nothing to commit' ]]; then + __CURRENT_GIT_BRANCH_IS_DIRTY='1' + fi +fi diff --git a/.zsh/syntax-highlighting b/.zsh/syntax-highlighting new file mode 160000 +Subproject d2715e2cb3294880bbc6a75b91288243054218d @@ -0,0 +1,22 @@ +LESSCMD="less -FXRS" + +export LESS_TERMCAP_mb=$'\e[1;37m' +export LESS_TERMCAP_md=$'\e[1;37m' +export LESS_TERMCAP_me=$'\e[0m' +export LESS_TERMCAP_se=$'\e[0m' +export LESS_TERMCAP_so=$'\e[1;47;30m' +export LESS_TERMCAP_ue=$'\e[0m' +export LESS_TERMCAP_us=$'\e[0;36m' + +export BROWSER=firefox +export PAGER=$LESSCMD + +# Aliases +alias alpine="alpine -p ""{imap.gmail.com/ssl/user=tom.willemsen@archlinux.us}remote_pinerc""" +alias cower="cower --color=always --target=$HOME/var/aur" +alias evolus-pencil="/usr/lib/evolus-pencil-svn/evolus-pencil.sh" +alias grep="grep --color=always" +alias less=$LESSCMD +alias ls="ls -F --color=always" +alias mysql="mysql --pager" +alias slrn="NNTPSERVER='news.gmane.org' slrn" @@ -0,0 +1,111 @@ +# -*- Mode: shell-script -*- +# Setup variables +PATH="${PATH}:/usr/local/bin:${HOME}/bin" + +HISTFILE=~/.zsh/histfile +HISTSIZE=1000 +SAVEHIST=1000 + +setopt notify +# Allow for functions in the prompt +setopt PROMPT_SUBST +setopt EXTENDED_GLOB + +zstyle :compinstall filename '/home/slash/.zshrc' + +autoload -Uz compinit +compinit + +# Functions +function env() +{ + exec /usr/bin/env "$@" | grep -v ^LESS_TERMCAP_ +} + +function line() +{ + let width=`expr $COLUMNS - ${#1} - 2` + for i in {1..$width} + do + echo -n \\x2d + done + echo " $1" +} + +function shutdown() +{ + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Stop +} + +function reboot() +{ + dbus-send --system --print-reply \ + --dest="org.freedesktop.ConsoleKit" \ + /org/freedesktop/ConsoleKit/Manager \ + org.freedesktop.ConsoleKit.Manager.Restart +} + +# Initialize colors. +autoload -U colors +colors + +# Autoload zsh functions. +fpath=(~/.zsh/functions $fpath) +autoload -U ~/.zsh/functions/*(:t) + +# Enable auto-execution of functions +typeset -ga preexec_functions +typeset -ga precmd_functions +typeset -ga chpwd_functions + +# Append git functions needed for prompt. +preexec_functions+='preexec_update_git_vars' +precmd_functions+='precmd_update_git_vars' +chpwd_functions+='chpwd_update_git_vars' + +# Set the prompt. +PROMPT='%{${fg[black]}%}%B$(line "$(~/.rootname.scm)")%b%{${fg[default]}%} +(%{${fg[magenta]}%}%m%{${fg[default]}%} %{${fg[cyan]}%}%B%~%b%{${fg[default]}%}) %(?.%{${fg[green]}%}O.%{${fg[red]}%}X)%{${fg[default]}%} %# ' +RPROMPT='$(prompt_git_info)%{${fg[default]}%}' + +# Set terminal name to current runnign application +case $TERM in + rxvt*) + precmd () { print -Pn "\e]0;%~\a" } + preexec () { print -Pn "\e]0;$1\a" } + ;; +esac + +# Set terminal keys +bindkey "\e[1~" beginning-of-line +bindkey "\e[4~" end-of-line +bindkey "\e[5~" beginning-of-history +bindkey "\e[6~" end-of-history +bindkey "\e[3~" delete-char +bindkey "\e[2~" quoted-insert +bindkey "\e[5C" forward-word +bindkey "\e0c" emacs-forward-word +bindkey "\e[5D" backward-word +bindkey "\e0d" emacs-backward-word +bindkey "\e\e[C" forward-word +bindkey "\e\e[D" backward-word +## for rxvt +bindkey "\e[8~" end-of-line +bindkey "\e[7~" beginning-of-line +## for non RH/Debian xterm, can't hurt for RH/Debian xterm +bindkey "\e0H" beginning-of-line +bindkey "\e0F" end-of-line +## for freebsd console +bindkey "\e[H" beginning-of-line +bindkey "\e[F" end-of-line + +# Show syntax highlighting when we're not running in emacs +if [ -z $EMACS ]; then + source ~/.zsh/syntax-highlighting/zsh-syntax-highlighting.zsh + + ZSH_HIGHLIGHT_STYLES[double-hyphen-option]='fg=blue' + ZSH_HIGHLIGHT_STYLES[single-hyphen-option]='fg=blue' +fi diff --git a/ChangeLog b/ChangeLog new file mode 100644 index 0000000..aed05e4 --- /dev/null +++ b/ChangeLog @@ -0,0 +1,6 @@ +2011-12-03 Tom Willemsen <tom@ryuslash.org> + + * .Xdefaults: Changed `*.color2' from #5a8e3a to #337733, + `*.color10' from #80b080 to #5ec95e, `*.color3' from #c9c990 to + #eac435, `*.color4' from RoyalBlue to #295874, `*.color12' from + #90a4c8 to RoyalBlue and `*.color13' from #ad68a6 to #9b859d diff --git a/bin/hlwm/capture-todo b/bin/hlwm/capture-todo new file mode 100755 index 0000000..a93d1da --- /dev/null +++ b/bin/hlwm/capture-todo @@ -0,0 +1,5 @@ +#!/bin/bash + +herbstclient rule pseudotile=on once +emacs -Q -l ~/.emacs.d/site-lisp/org-init.elc \ + --execute "(progn (org-capture nil \"t\") (delete-other-windows) (add-hook 'org-capture-after-finalize-hook 'kill-emacs))" diff --git a/bin/hlwm/show-todo b/bin/hlwm/show-todo new file mode 100755 index 0000000..991d3bd --- /dev/null +++ b/bin/hlwm/show-todo @@ -0,0 +1,5 @@ +#!/bin/bash + +grep --color=never "* \(TODO\|IN PROGRESS\|WAITING\)" org/notes.org \ + | sed 's/\*/ /g' \ + | xmessage -file - -default okay diff --git a/blog/__init__.py b/blog/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/blog/__init__.py +++ /dev/null diff --git a/blog/admin.py b/blog/admin.py deleted file mode 100644 index ca32d1f..0000000 --- a/blog/admin.py +++ /dev/null @@ -1,4 +0,0 @@ -from blog.models import Post -from django.contrib import admin - -admin.site.register(Post) diff --git a/blog/models.py b/blog/models.py deleted file mode 100644 index 126ba57..0000000 --- a/blog/models.py +++ /dev/null @@ -1,33 +0,0 @@ -from django.db import models -from main.models import Tag, Activity -from django.db.models.signals import post_save, post_delete - -class Post(models.Model): - subject = models.CharField(max_length=500) - body = models.TextField() - tags = models.ManyToManyField(Tag, null=True, blank=True) - postdate = models.DateTimeField(auto_now=True) - - def __unicode__(self): - return self.subject - -def post_saved_callback(sender, **kwargs): - if kwargs['created']: - acttype = 'add' - else: - acttype = 'edit' - - a = Activity(actcategory='blog', - actdescription=kwargs["instance"].subject, - acttype = acttype, - objpk = kwargs["instance"].pk) - a.save() - -def post_deleted_callback(sender, **kwargs): - a = Activity(actcategory='blog', - actdescription=kwargs["instance"].subject, - acttype = 'delete') - a.save() - -post_save.connect(post_saved_callback, sender=Post) -post_delete.connect(post_deleted_callback, sender=Post) diff --git a/blog/tests.py b/blog/tests.py deleted file mode 100644 index 2247054..0000000 --- a/blog/tests.py +++ /dev/null @@ -1,23 +0,0 @@ -""" -This file demonstrates two different styles of tests (one doctest and one -unittest). These will both pass when you run "manage.py test". - -Replace these with more appropriate tests for your application. -""" - -from django.test import TestCase - -class SimpleTest(TestCase): - def test_basic_addition(self): - """ - Tests that 1 + 1 always equals 2. - """ - self.failUnlessEqual(1 + 1, 2) - -__test__ = {"doctest": """ -Another way to test that 1 + 1 is equal to 2. - ->>> 1 + 1 == 2 -True -"""} - diff --git a/blog/urls.py b/blog/urls.py deleted file mode 100644 index a21c56a..0000000 --- a/blog/urls.py +++ /dev/null @@ -1,10 +0,0 @@ -from django.conf.urls.defaults import * - -urlpatterns = patterns('blog.views', - (r'^$', 'index'), - (r'^(?P<page>\d+)/$', 'index'), - (r'^post/(?P<post_id>\d+)/$', 'post'), - (r'^tags/$', 'tags'), - (r'^tag/(?P<tag_name>[\w_]+)/$', 'tag'), - (r'^atom/$', 'atom'), -) diff --git a/blog/views.py b/blog/views.py deleted file mode 100644 index 92ac55e..0000000 --- a/blog/views.py +++ /dev/null @@ -1,63 +0,0 @@ -# Create your views here. -from django.http import HttpResponse -from django.shortcuts import render_to_response -from django.template import Context, loader -from django.views.generic.simple import direct_to_template -from blog.models import Post, Tag - -def index(request, page=0): - item_count = 7 - - page = int(page) - start_num = (page * item_count) - end_num = start_num + item_count - - post_list = Post.objects.all().order_by("-postdate")[start_num:end_num] - - has_previous = page > 0 - has_next = end_num < Post.objects.all().count() - - c = { - 'postlist': post_list, - 'has_next': has_next, - 'has_previous': has_previous, - 'next_page': page + 1, - 'previous_page': page - 1 - } - - return direct_to_template(request, "blog/posts.html", c) - -def atom(request): - post_list = Post.objects.all().order_by("-postdate")[0:15] - c = { - 'postlist': post_list, - } - - return direct_to_template(request, "blog/rss.xml", c) - -def post(request, post_id): - post = Post.objects.filter(pk=post_id) - t = loader.get_template("blog/posts.html") - c = Context({ - 'postlist': post, - }) - - return HttpResponse(t.render(c)) - -def tags(request): - tag_list = Tag.objects.all() - t = loader.get_template("blog/tags.html") - c = Context({ - 'taglist': tag_list, - }) - - return HttpResponse(t.render(c)) - -def tag(request, tag_name): - post_list = Post.objects.filter(tags__name=tag_name) - t = loader.get_template("blog/posts.html") - c = Context({ - 'postlist': post_list, - }) - - return HttpResponse(t.render(c)) diff --git a/local_settings.py.example b/local_settings.py.example deleted file mode 100644 index fe6c1aa..0000000 --- a/local_settings.py.example +++ /dev/null @@ -1,16 +0,0 @@ -DEBUG = False -MARKDOWN_PATH = '' - -DATABASES = { - 'default': { - 'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'. - 'NAME': '', # Or path to database file if using sqlite3. - 'USER': '', # Not used with sqlite3. - 'PASSWORD': '', # Not used with sqlite3. - 'HOST': '', # Set to empty string for localhost. Not used with sqlite3. - 'PORT': '', # Set to empty string for default. Not used with sqlite3. - } -} - -# Make this unique, and don't share it with anybody. -SECRET_KEY = '00000000000000000000000000000000000000000000000000' diff --git a/main/__init__.py b/main/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/main/__init__.py +++ /dev/null diff --git a/main/admin.py b/main/admin.py deleted file mode 100644 index 093f769..0000000 --- a/main/admin.py +++ /dev/null @@ -1,4 +0,0 @@ -from main.models import Tag -from django.contrib import admin - -admin.site.register(Tag) diff --git a/main/models.py b/main/models.py deleted file mode 100644 index 8ecddec..0000000 --- a/main/models.py +++ /dev/null @@ -1,24 +0,0 @@ -from django.db import models - -class Tag(models.Model): - name = models.CharField(primary_key=True, max_length=200) - - def __unicode__(self): - return self.name - -class Activity(models.Model): - ACTCATEGORY_CHOICES = ( - ('blog', 'Blog post'), - ('project', 'Project page'), - ('link', 'Link'), - ) - ACTTYPE_CHOICES = ( - ('add', 'Add'), - ('edit', 'Edit'), - ('delete', 'Delete'), - ) - date = models.DateTimeField(auto_now=True) - actcategory = models.CharField(max_length=100, choices=ACTCATEGORY_CHOICES) - actdescription = models.CharField(max_length=500) - acttype = models.CharField(max_length=6) - objpk = models.CharField(max_length=300, null=True) diff --git a/main/signals.py b/main/signals.py deleted file mode 100644 index e69de29..0000000 --- a/main/signals.py +++ /dev/null diff --git a/main/tests.py b/main/tests.py deleted file mode 100644 index 2247054..0000000 --- a/main/tests.py +++ /dev/null @@ -1,23 +0,0 @@ -""" -This file demonstrates two different styles of tests (one doctest and one -unittest). These will both pass when you run "manage.py test". - -Replace these with more appropriate tests for your application. -""" - -from django.test import TestCase - -class SimpleTest(TestCase): - def test_basic_addition(self): - """ - Tests that 1 + 1 always equals 2. - """ - self.failUnlessEqual(1 + 1, 2) - -__test__ = {"doctest": """ -Another way to test that 1 + 1 is equal to 2. - ->>> 1 + 1 == 2 -True -"""} - diff --git a/main/urls.py b/main/urls.py deleted file mode 100644 index 9f861b5..0000000 --- a/main/urls.py +++ /dev/null @@ -1,4 +0,0 @@ -from django.conf.urls.defaults import * - -urlpatterns = patterns('main.views', - (r'^$', 'index')) diff --git a/main/views.py b/main/views.py deleted file mode 100644 index 91e20dd..0000000 --- a/main/views.py +++ /dev/null @@ -1,13 +0,0 @@ -from django.http import HttpResponse -from django.shortcuts import render_to_response -from django.template import Context, loader -from main.models import Activity - -def index(request): - activity_list = Activity.objects.all().order_by("-date")[:5] - t = loader.get_template("home.html") - c = Context({ - "activitylist": activity_list, - }) - - return HttpResponse(t.render(c)) diff --git a/manage.py b/manage.py deleted file mode 100644 index 6a43c99..0000000 --- a/manage.py +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/env python2 -from django.core.management import execute_manager -try: - import settings # Assumed to be in the same directory. -except ImportError: - import sys - sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized things.\nYou'll have to run django-admin.py, passing it your settings module.\n(If the file settings.py does indeed exist, it's causing an ImportError somehow.)\n" % __file__) - sys.exit(1) - -if __name__ == "__main__": - execute_manager(settings) diff --git a/pages/__init__.py b/pages/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/pages/__init__.py +++ /dev/null diff --git a/pages/management/__init__.py b/pages/management/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/pages/management/__init__.py +++ /dev/null diff --git a/pages/management/commands/__init__.py b/pages/management/commands/__init__.py deleted file mode 100644 index e69de29..0000000 --- a/pages/management/commands/__init__.py +++ /dev/null diff --git a/pages/management/commands/parse_markdown.py b/pages/management/commands/parse_markdown.py deleted file mode 100644 index 23ad2ec..0000000 --- a/pages/management/commands/parse_markdown.py +++ /dev/null @@ -1,42 +0,0 @@ -import os -import markdown - -from django.core.management.base import BaseCommand, CommandError - -from settings import MARKDOWN_PATH, DEPLOY_PATH - -class Command(BaseCommand): - help = 'Parse markdown files in %s' % MARKDOWN_PATH - - def handle(self, *args, **options): - for root, dirs, files in os.walk(MARKDOWN_PATH): - for file in files: - subdir = root.replace(MARKDOWN_PATH, "") - mdfile = '%s/%s' % (root, file) - mdtuple = os.path.splitext(file) - mdname = '%s/%s' % (subdir, mdtuple[0]) - htmlpath = '%s/templates/html_pages/%s' % (DEPLOY_PATH, mdname) - htmlfile = '%s/index.html' % htmlpath - - if options['verbosity'] == '3': - print 'Subdir: ', subdir - print 'Mdfile: ', mdfile - print 'Mdtuple: ', mdtuple - print 'Htmlpath: ', htmlpath - print 'Htmlfile: ', htmlfile - - if mdtuple[1] == '.mdwn' and os.path.exists(mdfile) \ - and (not os.path.exists(htmlfile) \ - or os.path.getmtime(mdfile) > os.path.getmtime(htmlfile)): - - if not os.path.exists(htmlpath): - os.makedirs(htmlpath) - - md = markdown.Markdown() - print 'Converting ', mdname, '-->', htmlfile, - wikilinks = 'wikilinks(base_url=%s/)' % subdir - def_list = 'def_list' - markdown.markdownFromFile(input=mdfile, output=htmlfile, encoding="utf-8", - extensions=[wikilinks, def_list]) - print ' ... succeeded' - diff --git a/pages/models.py b/pages/models.py deleted file mode 100644 index 71a8362..0000000 --- a/pages/models.py +++ /dev/null @@ -1,3 +0,0 @@ -from django.db import models - -# Create your models here. diff --git a/pages/urls.py b/pages/urls.py deleted file mode 100644 index 1c0cf82..0000000 --- a/pages/urls.py +++ /dev/null @@ -1,5 +0,0 @@ -from django.conf.urls.defaults import * - -urlpatterns = patterns('pages.views', - (r'^(?P<page>.+)/$', 'index'), -) diff --git a/pages/views.py b/pages/views.py deleted file mode 100644 index 7a44701..0000000 --- a/pages/views.py +++ /dev/null @@ -1,18 +0,0 @@ -import os.path - -from django.http import Http404 -from django.views.generic.simple import direct_to_template - -from settings import DEPLOY_PATH - -def index(request, page): - - template = 'html_pages/%s/index.html' % page - if not os.path.exists('%s/templates/%s' % (DEPLOY_PATH, template)): - raise Http404 - - c = { - "page": template, - } - - return direct_to_template(request, "pages/index.html", c) diff --git a/pictures/wallpapers/2960x1050/wallpaper-680196.jpg b/pictures/wallpapers/2960x1050/wallpaper-680196.jpg Binary files differnew file mode 100644 index 0000000..f34c5b5 --- /dev/null +++ b/pictures/wallpapers/2960x1050/wallpaper-680196.jpg diff --git a/settings.py b/settings.py deleted file mode 100644 index f19b8e3..0000000 --- a/settings.py +++ /dev/null @@ -1,90 +0,0 @@ -# Django settings for website project. -import os, sys -from local_settings import * - -DEPLOY_PATH = os.path.dirname(os.path.abspath(__file__)) -sys.path.insert(0, DEPLOY_PATH) - -TEMPLATE_DEBUG = DEBUG - -ADMINS = ( - ('Tom Willemsen', 'ryuslash@gmail.com'), -) - -MANAGERS = ADMINS - -# Local time zone for this installation. Choices can be found here: -# http://en.wikipedia.org/wiki/List_of_tz_zones_by_name -# although not all choices may be available on all operating systems. -# On Unix systems, a value of None will cause Django to use the same -# timezone as the operating system. -# If running in a Windows environment this must be set to the same as your -# system time zone. -TIME_ZONE = 'Europe/Brussels' - -# Language code for this installation. All choices can be found here: -# http://www.i18nguy.com/unicode/language-identifiers.html -LANGUAGE_CODE = 'en-us' - -SITE_ID = 1 - -# If you set this to False, Django will make some optimizations so as not -# to load the internationalization machinery. -USE_I18N = True - -# If you set this to False, Django will not format dates, numbers and -# calendars according to the current locale -USE_L10N = True - -# Absolute filesystem path to the directory that will hold user-uploaded files. -# Example: "/home/media/media.lawrence.com/" -MEDIA_ROOT = '' - -# URL that handles the media served from MEDIA_ROOT. Make sure to use a -# trailing slash if there is a path component (optional in other cases). -# Examples: "http://media.lawrence.com", "http://example.com/media/" -MEDIA_URL = '' - -# URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a -# trailing slash. -# Examples: "http://foo.com/media/", "/media/". -ADMIN_MEDIA_PREFIX = '/media/' - -# List of callables that know how to import templates from various sources. -TEMPLATE_LOADERS = ( - 'django.template.loaders.filesystem.Loader', - 'django.template.loaders.app_directories.Loader', -# 'django.template.loaders.eggs.Loader', -) - -MIDDLEWARE_CLASSES = ( - 'django.middleware.common.CommonMiddleware', - 'django.contrib.sessions.middleware.SessionMiddleware', - 'django.middleware.csrf.CsrfViewMiddleware', - 'django.contrib.auth.middleware.AuthenticationMiddleware', - 'django.contrib.messages.middleware.MessageMiddleware', -) - -ROOT_URLCONF = 'urls' - -TEMPLATE_DIRS = ( - # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates". - # Always use forward slashes, even on Windows. - # Don't forget to use absolute paths, not relative paths. - '%s/templates' % DEPLOY_PATH, -) - -INSTALLED_APPS = ( - 'django.contrib.auth', - 'django.contrib.contenttypes', - 'django.contrib.sessions', - 'django.contrib.sites', - 'django.contrib.messages', - # Uncomment the next line to enable the admin: - 'django.contrib.admin', - # Uncomment the next line to enable admin documentation: - # 'django.contrib.admindocs', - 'main', - 'blog', - 'pages', -) diff --git a/static/css/login.css b/static/css/login.css deleted file mode 100644 index 4b4dd1d..0000000 --- a/static/css/login.css +++ /dev/null @@ -1,13 +0,0 @@ -.form-row label { - float: left; - width: 9em; -} - -p.errornote { - margin: 0; - color: #CC0000; -} - -.errorlist { - color: #CC0000; -} diff --git a/static/css/main.css b/static/css/main.css deleted file mode 100644 index 8ca8ab3..0000000 --- a/static/css/main.css +++ /dev/null @@ -1,213 +0,0 @@ -* { - border: 0; - margin: 0; - padding: 0; -} - -a { - color: #FFC000; - text-decoration: none; -} - -a:hover { - text-decoration: underline; -} - -a:visited { - color: #FF8A00; -} - -body { - background-color: #000000; - color: #000000; - font-family: "DejaVu Sans", sans, sans-serif; -} - -dd { - margin-left: 40px; -} - -p { - margin: 1em 0px; -} - -ul { - margin: 1em 0; - padding-left: 40px; -} - -#body { - background-color: #777; -} - -#container { - margin: 0 auto 0 auto; - width: 700px; -} - -#container #footer { - background-color: #0C191C; - color: #EEEEEC; - font-size: 10px; - padding: 5px; - border-bottom-left-radius: 5px; - border-bottom-right-radius: 5px; -} - -#content { - margin-left: 100px; - padding: 5px 20px 1px 20px; -} - -#content .container { - color: #EEEEEC; -} - -#content .container .header { - background-color: transparent; - padding-bottom: 5px; - padding-left: 0; - padding-top: 5px; -} - -#content .container .header a { - color: inherit; - text-decoration: none; -} - -#content .container .header span.tagline { - color: #EEEEEC; - font-size: 12px; -} - -#content .container .header span.title { - background-color: #2E3436; - left: -5px; - padding: 5px; - position: relative; - top: -5px; -} - -#header { - background-color: #252A2B; -} - -#subheader { - background-color: #0c181b; - color: #fff; - text-align: right; - font-size: 12px; - padding: 5px; -} - -#logo { - float: left; - height: 100px; - margin: 0 20px 23px 0; - width: 100px; -} - -#ryu { - color: #F57900; - position: relative; - top: -3px; -} - -#slash { - position: relative; - top: 3px; -} - -#menu { - margin-left: -5px; - float: left; - width: 100px; - clear: left; -} - -#menu a { - color: #FFC000; - text-decoration: none; -} - -#title { - color: #EEEEEC; - height: 50px; - line-height: 50px; -} - -#title sup { - font-size: 11px; - position: relative; - top: 5px; -} - -.activity_even { - background-color: #2E3436; -} - -.activity_even, .activity_uneven { - border-bottom: 1px solid #444444; - color: #EEEEEC; - font-size: 12px; - margin: 0 20px; - padding: 2px 0 2px 5px; -} - -.activity_last { - border-bottom: none; -} - -.activity_uneven { - background-color: #0C191C; -} - -.container { - background-color: #0C191C; - border: 1px solid #2E3436; - margin-bottom: 20px; - padding: 2px 5px; - padding-left: 10px; -} - -.clear { - clear: both; -} - -.clearleft { - clear: left; -} - -.container .header { - background-color: #2E3436; - color: #F57900; - font-weight: bold; - margin: -2px -5px 0 -10px; - padding-left: 5px; -} - -.container .footer { - background-color: #2E3436; - color: #0C191C; - font-size: 10px; - margin: 0 -5px -2px -10px; - padding-left: 5px; -} - -.emblems { - text-align: right; - float: right; - margin-top: -2px; -} - -.markdown h3 { - margin: 1em 0; -} - -.navigation a { - color: #FFC000; -} - -.navigation a.next { - float: right; -} diff --git a/static/img/django.gif b/static/img/django.gif Binary files differdeleted file mode 100644 index a0548a6..0000000 --- a/static/img/django.gif +++ /dev/null diff --git a/static/img/hacker.png b/static/img/hacker.png Binary files differdeleted file mode 100644 index 5a2e185..0000000 --- a/static/img/hacker.png +++ /dev/null diff --git a/static/img/logo.png b/static/img/logo.png Binary files differdeleted file mode 100644 index a451578..0000000 --- a/static/img/logo.png +++ /dev/null diff --git a/static/img/logo_big.png b/static/img/logo_big.png Binary files differdeleted file mode 100644 index d6ac0d9..0000000 --- a/static/img/logo_big.png +++ /dev/null diff --git a/templates/.gitignore b/templates/.gitignore deleted file mode 100644 index c46f106..0000000 --- a/templates/.gitignore +++ /dev/null @@ -1 +0,0 @@ -html_pages diff --git a/templates/admin/login.html b/templates/admin/login.html deleted file mode 100644 index eba271f..0000000 --- a/templates/admin/login.html +++ /dev/null @@ -1,50 +0,0 @@ -{% extends "base.html" %} -{% load i18n %} - -{% block extrastyle %}{% load adminmedia %}{{ block.super }}<link rel="stylesheet" type="text/css" href="/static/css/login.css" />{% endblock %} - -{% block bodyclass %}login{% endblock %} - -{% block nav-global %}{% endblock %} - -{% block content_title %}{% endblock %} - -{% block breadcrumbs %}{% endblock %} - -{% block content %} -{% if form.errors and not form.non_field_errors and not form.this_is_the_login_form.errors %} -<p class="errornote"> -{% blocktrans count form.errors.items|length as counter %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %} -</p> -{% endif %} - -{% if form.non_field_errors or form.this_is_the_login_form.errors %} -{% for error in form.non_field_errors|add:form.this_is_the_login_form.errors %} -<p class="errornote"> - {{ error }} -</p> -{% endfor %} -{% endif %} - -<div id="content-main"> -<form action="{{ app_path }}" method="post" id="login-form">{% csrf_token %} - <div class="form-row"> - {% if not form.this_is_the_login_form.errors %}{{ form.username.errors }}{% endif %} - <label for="id_username" class="required">{% trans 'Username:' %}</label> {{ form.username }} - </div> - <div class="form-row"> - {% if not form.this_is_the_login_form.errors %}{{ form.password.errors }}{% endif %} - <label for="id_password" class="required">{% trans 'Password:' %}</label> {{ form.password }} - <input type="hidden" name="this_is_the_login_form" value="1" /> - <input type="hidden" name="next" value="{{ next }}" /> - </div> - <div class="submit-row"> - <label> </label><input type="submit" value="{% trans 'Log in' %}" /> - </div> -</form> - -<script type="text/javascript"> -document.getElementById('id_username').focus() -</script> -</div> -{% endblock %} diff --git a/templates/base.html b/templates/base.html deleted file mode 100644 index c6d6c26..0000000 --- a/templates/base.html +++ /dev/null @@ -1,61 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -<!DOCTYPE html> -<html> - <head> - <title>ryuslash | {% block subtitle %}linux and coding{% endblock %}</title> - <link href="/static/css/main.css" type="text/css" rel="stylesheet" /> - {% block extrastyle %}{% endblock %} - </head> - <body> - <div id="header"> - <img id="logo" src="/static/img/logo.png" width="100" height="100" /> - - <h1 id="title"> - <span id="ryu">ryu</span><span id="slash">slash</span> - </h1> - </div> - - <div id="subheader"> - <tt>This might just be my website.</tt> - </div> - - <div id="container"> - <div id="body"> - <div id="menu"> - <div class="container"> - <div class="header"> - root - </div> - - <a href="/">home</a><br /> - <a href="/blog/">blog</a><br /> - <a href="/Projects/">projects</a><br /> - </div> - - {% block submenu %}{% endblock %} - </div> - - <div id="content"> - {% block content %} - {% endblock %} - <div class="clear"></div> - </div> - </div> - - <div id="footer"> - Created by <a href="http://ryuslash.org">Tom Willemsen</a> - - <div class="emblems"> - <a href="http://www.djangoproject.com"> - <img src="/static/img/django.gif" alt="django emblem" /> - </a> - - <a href="http://www.catb.org/hacker-emblem/"> - <img src="/static/img/hacker.png" alt="hacker emblem" /> - </a> - </div> - </div> - </div> - </body> -</html> diff --git a/templates/blog/base.html b/templates/blog/base.html deleted file mode 100644 index e5caf88..0000000 --- a/templates/blog/base.html +++ /dev/null @@ -1,19 +0,0 @@ -{% extends "base.html" %} - -{% block subtitle %} - blog -{% endblock %} - -{% block extrastyle %} -<link href="/blog/atom/" type="application/atom+xml" rel="alternate" - title="Blog ATOM feed" /> -{% endblock %} - -{% block submenu %} -<div class="container"> - <div class="header"> - blog - </div> - <a href="/blog/atom/">feed</a> -</div> -{% endblock %} diff --git a/templates/blog/posts.html b/templates/blog/posts.html deleted file mode 100644 index d9bc72d..0000000 --- a/templates/blog/posts.html +++ /dev/null @@ -1,42 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -{% extends "blog/base.html" %} - -{% block content %} - {% if postlist %} - {% for post in postlist %} - <div class="container"> - <div class="header"> - <a href="/blog/post/{{ post.pk }}/"> - <span class="title">{{ post.subject }}</span> - </a> - </div> - {% autoescape off %} - {{ post.body|linebreaksbr }} - {% endautoescape %} - <div class="footer"> - Date posted: {{ post.postdate|date:"r" }} - Tags: - {% for tag in post.tags.all %} - {% if forloop.counter > 1 %}, {% endif %} - <a href="/blog/tag/{{ tag.name }}">{{ tag.name }}</a> - {% empty %} - None - {% endfor %} - </div> - </div> - {% endfor %} - - <div class="navigation"> - {% if has_next %} - <a class="next" href="/blog/{{ next_page }}/">next</a> - {% endif %} - - {% if has_previous %} - <a class="previous" href="/blog/{{ previous_page }}/">previous</a> - {% endif %} - </div> - {% else %} - Yeah I know, I'm boring. - {% endif %} -{% endblock %} diff --git a/templates/blog/rss.xml b/templates/blog/rss.xml deleted file mode 100644 index 9cc6df3..0000000 --- a/templates/blog/rss.xml +++ /dev/null @@ -1,25 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" ?> -<feed xmlns="http://www.w3.org/2005/Atom"> - <title>ryuslash.org</title> - <link href="http://ryuslash.org/feed/rss/" rel="self" /> - <link href="http://ryuslash.org/" /> - <id>http://ryuslash.org/blog/</id> - <author> - <name>Tom Willemsen</name> - </author> - <updated>2011-10-29T23:16:00+01:00</updated> - - {% for post in postlist %} - <entry> - <title>{{ post.subject }}</title> - <link href="http://ryuslash.org/blog/post/{{ post.pk }}/" /> - <id>http://ryuslash.org/blog/post/{{ post.pk }}/</id> - <updated>{{ post.postdate|date:"c" }}</updated> - <content type="xhtml" xml:base="http://ryuslash.org/"> - <div xmlns="http://www.w3.org/1999/xhtml"> - {{ post.body|linebreaksbr }} - </div> - </content> - </entry> - {% endfor %} -</feed> diff --git a/templates/blog/tags.html b/templates/blog/tags.html deleted file mode 100644 index a180634..0000000 --- a/templates/blog/tags.html +++ /dev/null @@ -1,19 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -{% extends "blog/base.html" %} - -{% block subtitle %} - blog/tags -{% endblock %} - -{% block content %} - <ul> - {% for tag in taglist %} - <li> - <a href="/blog/tag/{{ tag.name }}">{{ tag.name }}</a> - </li> - {% empty %} - Sorry, no tags here. - {% endfor %} - </ul> -{% endblock %} diff --git a/templates/home.html b/templates/home.html deleted file mode 100644 index e5c2fed..0000000 --- a/templates/home.html +++ /dev/null @@ -1,87 +0,0 @@ -{% extends "base.html" %} - -{% block content %} - This will, hopefully, eventually, become my website. - <strong>Rejoice!</strong> - <p> - Some places you can already find me: - <ul> - <li> - <a href="https://diasp.org/u/ryuslash">Diaspora*</a> - I'm here - all the time. - </li> - <li> - <a href="http://identi.ca/ryuslash">Identi.ca</a> - Don't post - much, but I'm usually there. - </li> - <li> - <a href="http://stackoverflow.com/users/459915/slash">Stack Overflow</a> - - Don't really do much there, but I did just get my - first reputation points. - <br/> - <a href="http://stackoverflow.com/users/459915/slash"> - <img src="http://stackoverflow.com/users/flair/459915.png?theme=dark" - width="208" height="58" - alt="profile for slash at Stack Overflow, Q&A - for professional and enthusiast - programmers" - title="profile for slash at Stack Overflow, Q&A - for professional and enthusiast programmers" /> - </a> - </li> - </ul> - </p> - - {% for activity in activitylist %} - <div class="activity_{% cycle 'even' 'uneven' %} - {% if forloop.last %}activity_last{% endif %}"> - {{ activity.date|date:'d M H:i:' }} - {% if activity.actcategory == "blog" %} - {% if activity.acttype == "add" %} - I ranted about - {% endif %} - {% if activity.acttype == "edit" %} - I changed my opinion about - {% endif %} - {% if activity.acttype == "delete" %} - I lost my opinion about - {% endif %} - {% if activity.objpk %} - <a href="/blog/post/{{ activity.objpk }}/"> - {% endif %} - {% endif %} - {% if activity.actcategory == "project" %} - {% if activity.acttype == "add" %} - I started a project named - {% endif %} - {% if activity.acttype == "edit" %} - I updated the info on project - {% endif %} - {% if activity.acttype == "delete" %} - I quit project - {% endif %} - {% if activity.objpk %} - <a href="/projects/{{ activity.objpk }}/"> - {% endif %} - {% endif %} - {% if activity.actcategory == "link" %} - {% if activity.acttype == "add" %} - I found - {% endif %} - {% if activity.acttype == "edit" %} - I corrected - {% endif %} - {% if activity.acttype == "delete" %} - I unlinked - {% endif %} - {% if activity.objpk %} - <a href="/links/"> - {% endif %} - {% endif %} - {{ activity.actdescription }} - {% if activity.objpk %} - </a> - {% endif %} - </div> - {% endfor %} -{% endblock %} diff --git a/templates/pages/index.html b/templates/pages/index.html deleted file mode 100644 index 0f295e7..0000000 --- a/templates/pages/index.html +++ /dev/null @@ -1,8 +0,0 @@ -{% extends "base.html" %} - -{% block content %} -<div class="markdown"> - {% include page %} -</div> -<br/> -{% endblock %} diff --git a/templates/projects/base.html b/templates/projects/base.html deleted file mode 100644 index d3654cc..0000000 --- a/templates/projects/base.html +++ /dev/null @@ -1,3 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -{% extends "base.html" %} diff --git a/templates/projects/project_detail.html b/templates/projects/project_detail.html deleted file mode 100644 index 1c19f4f..0000000 --- a/templates/projects/project_detail.html +++ /dev/null @@ -1,52 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -{% extends "projects/base.html" %} - -{% block subtitle %} - projects/{{ object.name }} -{% endblock %} - -{% block content %} - <div class="container"> - <div class="header"> - <span class="title">{{ object.name }}</span> - <span class="tagline">{{ object.tagline }}</span> - </div> - - - <p> - {% autoescape off %} - {{ object.description|linebreaksbr }} - {% endautoescape %} - </p> - </div> - - <div class="container"> - <div class="header"> - <span class="title">Stats</title> - </div> - {% for key, value in stats.items %} - {% if value %} - {{ key }}: {{ value }}<br/> - {% endif %} - {% endfor %} - </div> - - <div class="container"> - <div class="header"> - <span class="title">Links</title> - </div> - {% for key, value in links.items %} - {% if value %} - <a href="{{ value }}">{{ key }}</a><br/> - {% endif %} - {% endfor %} - </div> - - {% if object.screenshots %} - <p> - Screenshots here - </p> - {% endif %} - -{% endblock %} diff --git a/templates/projects/project_list.html b/templates/projects/project_list.html deleted file mode 100644 index 1ab750c..0000000 --- a/templates/projects/project_list.html +++ /dev/null @@ -1,20 +0,0 @@ -<!-- -*- Mode: django-html-mumamo -*- --> - -{% extends "projects/base.html" %} - -{% block subtitle %} - projects -{% endblock %} - -{% block content %} - {% if object_list %} - <dl> - {% for project in object_list %} - <dt><a href="/projects/{{ project.slug }}/">{{ project.name }}</a></dt> - <dd>{{ project.tagline }}</dd> - {% endfor %} - </dl> - {% else %} - Well, you know me, I'm lazy. Got nothing going on. - {% endif %} -{% endblock %} diff --git a/urls.py b/urls.py deleted file mode 100644 index 26aa007..0000000 --- a/urls.py +++ /dev/null @@ -1,21 +0,0 @@ -from django.conf.urls.defaults import * -from settings import DEPLOY_PATH, DEBUG - -# Uncomment the next two lines to enable the admin: -from django.contrib import admin -admin.autodiscover() - -urlpatterns = patterns('', - (r'^blog/', include("blog.urls")), - (r'^admin/', include(admin.site.urls)), - (r'^', include("main.urls")), -) - -if DEBUG: - urlpatterns += patterns('', - (r'^static/(?P<path>.*)$', 'django.views.static.serve', {'document_root': '%s/static' % DEPLOY_PATH}) - ) - -urlpatterns += patterns('', - (r'^', include("pages.urls")) -) |