####### # # E-scripts on some basic debian things # # Note 1: use the eev command (defined in eev.el) and the # ee alias (in my .zshrc) to execute parts of this file. # Executing this file as a whole makes no sense. # # Note 2: be VERY careful and make sure you understand what # you're doing. # # Note 3: If you use a shell other than zsh things like |& # and the for loops may not work. # # Note 4: I always run as root. # # Note 5: some parts are too old and don't work anymore. Some # never worked. # # Note 6: the definitions for the find-xxxfile commands are on my # .emacs. # # Note 7: if you see a strange command check my .zshrc -- it may # be defined there as a function or an alias. # # Note 8: the sections without dates are always older than the # sections with dates. # # This file is at # or at . # See also , # , # , # , # and . # ####### # «.sudo» (to "sudo") # «.sudo-src» (to "sudo-src") # «.debian-menus» (to "debian-menus") # «.debconf» (to "debconf") # Everything related to making or inspecting .debs or moving them to # the right places was moved to dpkg.e. # (find-es "dpkg") ##### # # sudo # 2000nov17 # ##### # «sudo» (to ".sudo") # (find-es "sudo") # (find-es "cdd" "sudo") # (find-status "sudo") # (find-vldifile "sudo.list") # (find-fline "/usr/doc/sudo/") # (find-man "5 sudoers") # (find-fline "/usr/doc/sudo/examples/sudoers") # (find-fline "/etc/sudoers") ## Edrx changes: ## (find-es "debian" "sudo") ## (find-fline "/usr/share/doc/sudo/examples/sudoers" "User_Alias") ## (find-fline "/usr/share/doc/sudo/examples/sudoers" "\nFULLTIMERS") # id sudo -u aleph id cat > $EEG <<'---' id sudo id sudo pwd sudo -u aleph id --- eeg su - edrx # done. # # (find-man "8 visudo") # (find-man "8 visudo" "ENVIRONMENT") # This is a cheap way to make visudo check the syntax of /etc/sudoers. EDITOR=echo visudo EDITOR=touch visudo # EDITOR=nano visudo # # (find-man "8 sudo") # (find-man "5 sudoers") # (find-man "5 sudoers" "NOPASSWD and PASSWD") # (find-man "5 sudoers" "\nEXAMPLES") # (find-man "8 visudo") # (find-es "debian" "sudo") User_Alias FULLTIMERS = edrx, aleph, beth FULLTIMERS ALL = NOPASSWD: ALL # # A problem: edrx can sudo root without password, but not sudo # aleph... # (...) # And the naive way of gdb'ing sudo fails because gdb can't trace suid # processes, I think. Where do the docs say that?? # (find-es "gdb" "zcatinfo-gdb") ##### # # single-stepping through dpkg-source # ##### # debsource $DEBIAN/hamm/hamm/source/utils makepatch 1.13 -3 function debsource () { rm -Rv /usr/src/$2-$3 cd /usr/src/ dpkg-source -x $1/$2_$3$4.dsc cd /usr/src/$2-$3/ } debian/main/source/base/modutils_2.1.85-11.dsc rm -Rv /usr/src/modutils-2.1.85/ cd /usr/src/ rm -Rv ~/modutils-2.1.85/ # (perldb "perl /usr/bin/dpkg-source -x /debian/main/source/base/modutils_2.1.85-11.dsc") # (find-fline "/usr/bin/dpkg-source") # (find-fline "/usr/lib/dpkg/controllib.pl") # (find-fline "/usr/lib/dpkg/") ##### # # lintian # ##### pdsc $SDEBIAN/dists/potato/main/source/devel/lintian_0.9.5.dsc dpkg -i $SDEBIAN/dists/potato/main/binary-all/devel/lintian_0.9.5.deb # (find-fline "/usr/doc/lintian/") # (find-fline "/usr/doc/packaging-manual/") lynx /usr/doc/packaging-manual/packaging.html/index.html lynx /usr/doc/debian/FAQ/debian-faq.html ##### # # First things on ifigenia (to be done by hand) # 00jan31 # ##### # Install slink on /dev/hdb1; select zsh, emacs19 and smail, deselect # everything that is useless. mkdir /home/root emacs /etc/passwd # then remove root's password, copy to a "broot" login, set root's # home to /home/root, set shell to /usr/bin/zsh. cd /home/root mkdir public_html mcopy a:page.tgz cd public_html/ tar -xvzf ../page.tgz cd a/ cp .emacs .. cp eev.el .. cp .zshrc .. # log as root (now using zsh and /home/root). ##### # # On ifigenia, after the slink install, after page.tgz # 00jan30 # ##### mkdir /C mount /dev/hda1 /C -t vfat mkdir -p /C/edrx mount /dev/cdrom /cdrom cd /cdrom/tools/lodlin16/ cp -v loadlin.exe /C/edrx/ cp -v /vmlinuz /C/edrx/k20xx cat > /C/edrx/b1.bat <<'---' smartdrv /C c:\edrx\loadlin c:\edrx\k20xx root=/dev/hdb1 ro vga=1 --- cat > /C/edrx/README <<'---' Use F8 to boot DOS instead of Windows cd \edrx b1 --- # (find-fline "/cdrom/tools/lodlin16/") # (find-fline "/C/edrx/") # Prepare for telnets: # (find-fline "~/EXPECT/ifigenia") adduser edrx emacs /etc/passwd ##### # # dict # 99dec15 # ##### Pgrep m/dictionary/i dmissing usr/dict apti dict dictd dict-foldoc dict-jargon # (find-vldifile "dictd.list") # (find-vldifile "dictd.postinst" "uncomment") # (find-fline "/etc/dictd.conf" "database jargon") /etc/init.d/dictd restart dict hacker # (find-vldifile "dict.list") # (find-fline "/usr/doc/dict/") # (find-vldifile "dict-foldoc.list") # (find-fline "/usr/doc/dict-foldoc/") # (find-vldifile "dictd.list") # (find-fline "/usr/doc/dictd/") gzip -cd < /usr/share/dictd/foldoc.dict.dz > /tmp/foldoc.dict # (find-fline "/tmp/foldoc.dict") ##### # # The Debian menu system # 2000apr15 # ##### # «debian-menus» (to ".debian-menus") # (find-node "(menu)Top") # (find-node "(menu)Section 5.1" "~/.menu") # (find-fline "/usr/doc/debian-policy/menu-policy.text.gz") # (find-fline "/usr/lib/menu/") # (find-fline "/usr/doc/menu/") ##### # # debconf # 2001aug02 # ##### # «debconf» (to ".debconf") # (find-status "debconf-tiny") # (find-vldifile "debconf-tiny.list") # (find-fline "/var/lib/debconf") # (find-status "debconf") # (find-vldifile "debconf.list") # (find-fline "/usr/doc/debconf/") # (find-fline "/usr/doc/debconf/introduction.txt.gz") # (find-fline "/usr/doc/debconf/introduction.txt.gz" "suppress the questions") # (find-fline "/usr/doc/debconf/usersguide.txt.gz") # (find-fline "/usr/doc/debconf/usersguide.txt.gz" "libterm-readline-gnu-perl") # (find-fline "/usr/doc/debconf/usersguide.txt.gz" "DEBCONF_FRONTEND=") # (find-fline "/usr/doc/debconf/tutorial.txt.gz") # (find-fline "/usr/doc/debconf/specification.txt.gz" "The configuration space") dpkg -l --root=/var/_subdebian # (find-subdebfile " # (eeman "3 confmodule") # (eeman "3 Debian::Debconf::Client::ConfModule") # (eeman "8 dpkg-reconfigure") # (eeman "8 dpkg-preconfigure") ##### # # diversions # 2004oct16 # ##### # (find-status "pentium-builder") # (find-vldifile "pentium-builder.list") # (find-udfile "pentium-builder/") # (find-vldifile "pentium-builder.preinst") # (find-vldifile "pentium-builder.postinst") # (find-vldifile "pentium-builder.prerm") # (find-vldifile "pentium-builder.postrm") # (find-man "8 dpkg-divert") # (find-fline "/var/lib/dpkg/diversions") # (find-man "1 builder-cc") # (find-man "1 builder-c++") # (find-udfile "pentium-builder/changelog.gz") # (find-udfile "pentium-builder/copyright") # (find-udfile "pentium-builder/README.Debian") # (find-fline "/usr/bin/builder-c++") # (find-fline "/usr/bin/builder-cc") # (find-fline "/usr/bin/gcc") # (find-fline "/usr/bin/g++") (cd /var/lib/dpkg/info/ && find *) | grep temp | sort \ | awk '{printf "# (find-vldifile \"%s\")\n", $1}' | tee ~/o # (find-vldifile "auctex.templates") # (find-vldifile "base-config.templates") # (find-vldifile "clanlib0-common.templates") # (find-vldifile "cvs.templates") # (find-vldifile "debconf.templates") # (find-vldifile "esound-common.templates") # (find-vldifile "gmc.templates") # (find-vldifile "gnuplot.templates") # (find-vldifile "lynx.templates") # (find-vldifile "mysql-server.templates") # (find-vldifile "netbase.templates") # (find-vldifile "ppp.templates") # (find-vldifile "setserial.templates") # (find-vldifile "ssh.templates") # Local Variables: # coding: no-conversion # ee-delimiter-hash: "\n#\n" # ee-delimiter-percent: "\n%\n" # ee-anchor-format: "«%s»" # ee-charset-indicator: "Ñ" # End: