Jumaat, 29 Januari 2016

XScreenSaver

su -c 'apt-get install xscreensaver xscreensaver-gl-extra xscreensaver-data-extra'

su -c 'apt-get remove gnome-screensaver'

xscreensaver-demo

su -c 'nano /etc/init.d/xscreensaver'

#!/bin/sh
# /etc/init.d/xscreensaver

### BEGIN INIT INFO
# Provides:          skeleton
# Required-Start:    $remote_fs $syslog
# Required-Stop:     $remote_fs $syslog
# Should-Start:      $portmap
# Should-Stop:       $portmap
# X-Start-Before:    nis
# X-Stop-After:      nis
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# X-Interactive:     true
# Short-Description: Example initscript
# Description:       This file should be used to construct scripts to be
#                    placed in /etc/init.d.
### END INIT INFO

# The following part always gets executed.
echo "This part always gets executed"

# The following part carries out specific functions depending on arguments.
case "$1" in
  start)
    xscreensaver -nosplash

    echo "Starting xscreensaverxscreensaver"
    echo "xscreensaver is alive"
    ;;
  stop)
    echo "Stopping xscreensaver"
    echo "xscreensaver is dead"
    ;;
  *)
    echo "Usage: /etc/init.d/xscreensaver {start|stop}"
    exit 1
    ;;
esac

exit 0

su -c 'chmod 755 /etc/init.d/xscreensaver'

su -c 'update-rc.d xscreensaver defaults'

bashrc dengan lokasi ke binari peribadi

# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.

# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022

# if running bash
if [ -n "$BASH_VERSION" ]; then
    # include .bashrc if it exists
    if [ -f "$HOME/.bashrc" ]; then
    . "$HOME/.bashrc"
    fi
fi

# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/Projek" ] ; then
    for apps in /home/dekwan/Projek/*/bin/*;
    do PATH="$apps:$PATH";
    done
fi

Khamis, 21 Januari 2016

xzdec: (stdin): File format not recognized

Problem:

$ tlmgr update --self --all

(running on Debian, switching to user mode!)
xzdec: (stdin): File format not recognized
First directive needs to be 'name', not <html><frameset> <frame id='top' src="http://210.187.26.4/disable/disable.htm?ip=210.187.26.2&type=Anonymizers&url=ossm.utm.my/tex-archive/systems/texlive/tlnet/tlpkg/texlive.tlpdb"><noframes> <body>Your browse does not support frame!</body> </noframes> </frameset> </html> at /usr/share/texlive/tlpkg/TeXLive/TLPOBJ.pm line 108, <$fh> line 1.

Solution:

Change repo to other site.

$ tlmgr option repository http://mirror.switch.ch/ftp/mirror/tex/systems/texlive/tlnet

(running on Debian, switching to user mode!)
tlmgr: setting default package repository to http://mirror.switch.ch/ftp/mirror/tex/systems/texlive/tlnet

$ tlmgr update --self --all