2004-07-13
Some cool bash/Linux stuff: If you're using bash, put a line TMOUT=600 in /root/.bashrc. The user will . . . typing, I created the following line in my .bash_profile file: export CDPATH=".:/mnt/es-groups/EWII" . . . in the project's documentation directory; bash even tab-completes. UNIX Commands No One Ever . . .
1K - last updated 2005-03-19 13:41 UTC by 1453
2004-08-06
''This is for unredeemed hackers who must see the raw bits to be happy.'' -- Solaris truss man page They . . . can be found with ulimit -n if you're using the Bash shell). What is nasty, is that that message doesn't . . .
3K - last updated 2005-03-19 11:14 UTC by 1453
2006-04-27 Perl modules and CGI
Suppose you have a bunch of Perl scripts and modules. Those modules have differing versions and you don't . . . You could add the following lines in $HOME/.bash_profile: # separate multiple directories with . . .
2K - last updated 2006-04-27 08:39 UTC by 1453
2006-10-04 Mod perl and Slackware part 2
The previous day, I thought I had Apache with mod_perl working on Slackware 10.2, but alas, funny segfaults . . . create a user: # useradd -g users -m -s /bin/bash apache_mod_perl # passwd apache_mod_perl Login . . . make && make install Add the following line to .bash_profile: export PERLLIB=$PERLLIB:$HOME/lib/perl5/5.8.6:\ . . . '''Group''' to users Save, exit and edit ~/.bash_profile. Add the following line: export PATH=$HOME/apache/bin:$PATH . . .
3K - last updated 2006-10-24 06:56 UTC by bvankuik
2010-11-26 From which host am I logged in
Sometimes you want to adjust your settings in bashrc, depending from which host you are logging in from. . . .
1K - last updated 2010-11-26 15:27 UTC by 1453
2011-03-03 From which host am I logged in
A previous entry documented on how to change your settings in bashrc, according to from which host you . . .
2K - last updated 2011-03-03 17:31 UTC by 1453
2011-08-30 Creating specific password lists with John the Ripper
For security purposes, you sometimes want a dictionary with possible passwords. Perhaps you want to assess . . . path, by adding the following line to your ~/.bashrc: export PATH=$HOME/opt/john-1.7.8/run Logout, . . .
5K - last updated 2011-08-31 10:58 UTC by 1453
2013-03-27 warning Setting locale failed
I was getting the error from all kinds of Linux programs about "setting locale failed". For example, . . . Linux side, by unsetting the LC_CTYPE in your .bashrc. Add the following line: unset LC_CTYPE However, . . . OS X side, by adding the following two lines to .bash_profile: unset LC_CTYPE export LANG="en_US.UTF-8" . . .
3K - last updated 2014-03-28 13:06 UTC by 1453
2014-04-16 Python vi keybindings on OS X
If you're used to vi keybindings, and you use Python interactively, you're going to do a lot of cursing . . . rlcompleter import readline Add a line to your .bashrc which makes Python run .pythonrc when it starts . . .
1K - last updated 2014-04-16 12:40 UTC by 1453
2016-06-02 Good error messages in Xcode Run Scripts phase
Xcode has an option to run a script when building. This is necessary for example when using [https://github.com/Carthage/Carthage . . . a Run Script phase, change the shell to /bin/bash. Then add an error message by checking for prerequisites, . . .
2K - last updated 2016-06-06 12:43 UTC by 1453
2019-04-23 ISO date on macOS
To print the current date in ISO 8601 format on macOS: $ date +%Y-%m-%dT%H:%M:%S 2019-04-23T14:44:46 . . . bit. To correct this, we'll need to do some bash wizardry: $ zone=$(date +%z);datetime=$(date +%Y-%m-%dT%H:%M:%S); . . .
1K - last updated 2019-04-23 12:55 UTC by 1453
A Small Oracle 9i
== HOWTO: A Small 9i Database == This thing is HUUUUUGE... Yeah, it's a big beast. But if you need an . . . -o rss,vsz,cmd --sort=rss -u oracle 1304 4160 -bash 1336 4172 -bash 7000 113148 ora_ckpt_orcl 7412 . . .
13K - last updated 2005-03-18 22:41 UTC by 1453
Bash
= Online resources = [http://ldp.nl.uu.net/LDP/abs/html/ Advanced Bash-Scripting Guide] = Changing numbering . . . # Then remove the extension num=${num%.png} # Bash interprets a leading zero as an octal number; . . . You can't really return values in a function in bash, however you ''can'' echo text and then catch . . . To parse parameters and cookies, include [http://bashlib.sourceforge.net/ Bashlib] like this: . ./bashlib . . . = Script displaying feedback = The following bash function can be included in your scripts to provide . . .
10K - last updated 2012-09-14 07:29 UTC by 1453
bashrc
text/plain
9K - last updated 2007-11-13 12:41 UTC by 1453
Debian Sarge on Xen backup copy
Quick instructions for installing a Debian Sarge VM on Xen http://wiki.xensource.com/xenwiki/DebianSarge . . . chroot /mnt/disk /bin/bash cd /etc; vi hostname hosts resolv.conf Add minimal . . .
3K - last updated 2006-09-24 13:52 UTC by 1453
JDeveloper on Linux
Here I'm listing some news, tips, problems and issues I found while running JDeveloper on Linux. For . . . lines in /etc/profile or your own user's .bash_profile. export JAVA_HOME=/usr/java/j2sdk1.4.2_01 . . .
15K - last updated 2006-01-30 14:56 UTC by 1453
macOS
= The Library folder = Since uninstalling Mac apps consists of dragging the .app folder to the trash, . . . 0 31 0 2435764 1836 - S 81c8a80 ttys000 0:00.30 -bash 502 30395 28154 4006 0 51 -20 2451444 6436 - R<+ . . . 31 0 2435764 1808 - S+ aa512a0 ttys001 0:00.10 -bash 502 28315 28314 4006 0 31 0 2435764 1840 - S 81b52a0 . . . ttys002 0:00.37 -bash As you'll see in the PRI column, the priority . . .
7K - last updated 2017-06-22 06:24 UTC by 1453
Random Linux Stuff
= Swap caps lock and Escape on the console = If you run Debian, add the following line to /etc/console-tools/remap: . . . or whatever you view files in. Use the following bash script to put a sequential number in front of . . . sorts the files alphabetically. #!/bin/bash IFS=" " n="1" FILES=`ls *mp3` for i in $FILES; . . . there are too much of them: $ rm -fr plot-9_X* -bash: /usr/bin/rm: Argument list too long You'll need . . .
4K - last updated 2007-05-03 07:47 UTC by bvankuik
Screen
When you're ssh'ing to a specific remote server regularly, [http://www.gnu.org/software/screen/screen.html . . . live. I ended up adding the following to my .bashrc # -- if $STARTED_SCREEN is set, don't try it . . . echo "Screen failed! continuing with normal bash startup" else mkdir -p $HOME/log/screen-logs fi . . . echo "Screen failed! continuing with normal bash startup" Wait one second then attempt to reattach . . .
7K - last updated 2009-05-26 14:24 UTC by 1453
Shared directories
Sometimes you need a couple of users to share a directory, for example a number of developers who test . . . In the shell initialization file (for instance .bashrc), add the line umask 002 Tip: if users encounter . . . the group write bit.'' Setting the umask in .bashrc will not affect the way that directories and . . .
2K - last updated 2009-10-28 10:47 UTC by 1453
Shell scripting and CGI
You may want to go here: [[Bash]] . . .
1K - last updated 2012-09-14 07:25 UTC by 1453
Shell tricks
= Shared accounts = Sometimes, you have to use shell accounts which are shared with other people. Of . . . a handy trick. Add the following lines to the .bashrc file and adjust the first variable. I'm assuming . . . your settings here set -o vi ;; esac If you use bash as your shell, this can be a lot shorter. The . . . correct this, put the following lines in your .bashrc if you're using bash on the other end (note . . .
2K - last updated 2014-02-12 13:23 UTC by 1453
Software RAID
= Testing and setting up RAID-1 = Install a minimal and configure with RAID-1, with a small RAID-1 partition . . . If your bash shell says <tt>cannot overwrite existing file</tt>, . . .
6K - last updated 2007-08-10 14:43 UTC by 1453
Source code version management
= How do I control my source code? = In the past, you may have had the problem that while working on . . . in your local profile file. Add these lines (bash shells): * export CVSROOT=/home/cvsroot * export . . .
5K - last updated 2006-03-03 21:10 UTC by 1453
SSH
= Create a VNC tunnel to work = Suppose your home and organization's network looks like this: +-----Organization-Network-----+ . . . the connection open indefinitely and use the bash shell, put the following lines in the .bashrc . . . TMOUT is important here; after 600 seconds, the bash shell detects inactivity and logs you out. However, . . . This can be used in scripts, for instance in .bashrc. # If we're logging in through SSH, write this . . .
7K - last updated 2008-11-14 09:17 UTC by 1453
Turn off beep
To turn off the beep in several applications: For bash and other readline applications, create a new . . . For less, put the following line in your $HOME/.bashrc: export LESS="-Q" For vi, put the following . . .
1K - last updated 2009-02-09 14:47 UTC by 1453
unix bench xen budgetdedicated
BYTE UNIX Benchmarks (Version 4.0.1) System -- vankuik Start Benchmark Run: Wed Mar 8 11:44:14 CET 2006 . . . lrwxrwxrwx 1 root root 4 Feb 1 13:30 /bin/sh -> bash /bin/sh: symbolic link to `bash' /dev/hda1 1032440 . . .
3K - last updated 2006-03-15 11:47 UTC by 1453
Using Screen
= THIS IS AN OLD VERSION = PLEASE CHECK THE MORE RECENT PAGE: [[Screen]]. When you're ssh'ing to a specific . . . live. I ended up adding the following to my .bashrc # -- if $STARTED_SCREEN is set, don't try it . . . echo "Screen failed! continuing with normal bash startup" else mkdir -p $HOME/log/screen-logs fi . . . echo "Screen failed! continuing with normal bash startup" Wait one second then attempt to reattach . . .
6K - last updated 2009-05-20 09:04 UTC by 1453
vankuik.nl
= Latest weblog entries = <journal 5> = Weblog Archive = [[Weblog_entries_2024]] [[Weblog_entries_2023]] . . . for all your Subversion tricks * [[git]] * [[Bash]] * [[UNIX_Toolkit]] Explanation of several operating . . .
4K - last updated 2024-04-16 10:29 UTC by bartvk
29 pages found.