Categories
debian Uncategorized

screensaver

found a nice screen blurring command that relies on ImageMagick


#!/bin/sh -e

# Take a screenshot
#scrot /tmp/screen_locked.png
import -window root /tmp/screen_locked.png

# Pixellate it 10x
mogrify -scale 10% -scale 1000% /tmp/screen_locked.png

# Lock screen displaying this image.
i3lock -i /tmp/screen_locked.png

# Turn the screen off after a delay.
sleep 60; pgrep i3lock && xset dpms force off

then we need xautolock, but there is no xautolock. so instead we try
https://github.com/fgsch/xidle

which locks only from the command line, not from the .i3/config.  so we compile xautolock from source fromhttps://github.com/l0b0/xautolock

finally we need to add a line to an x startup script like .xsessionrc or .i3/config to add the line

exec xautolock -time 1 -locker '~/.local/bin/fuzzy_lock.sh' &

Categories
debian Uncategorized

volume from mint command line

pactl set-sink-volume 0 +15%

pactl set-sink-volume 0 -5dB
Categories
debian Uncategorized

PIXMA 100 setup

this is a cheap and apparently old printer.  Important points:

  • It doesn’t connect to my WiFi — it needs a WPS button on the router
  • It doesn’t work with USB3 ports, needs to be connected to an older port
  • It needs to be rebooted prior it each printing session
  • The paper tray needs to be unfolded from the back, and the paper catcher needs to be unfolded from the front.
Categories
debian

wireless on debian toshiba satellite

  1. lspci, look for wireless network
  2. the drivers are proprietary, non-free so google for the driver and install.  in this case it was firmware-iwlwifi.
  3. wireless-tools
  4. wicd (networkmanager also may have been helpful at some time, but i think its best to have only 1 of them installed.)
  5. reboot and check the hardware wireless switch is on.  (removed something called avahi-auto ipd because i wasnt getting connection and i thought it was interfering, turned out to be the wireless switch, doesn’t seem to have messed anything up either way and i don’t know what it  does.)
Categories
debian Uncategorized

wipe failing drive using systemrescuecd

ddrescue --force /dev/zero /dev/sdb log.txt
Categories
debian Uncategorized

fill out and sign a PDF on debian

  1. fill out form with xournal and export pdf.  (oowriter didn’t read xournal’s output even with the libreoffice pdf import extension, but the xournal’d pdf did print, gimp was able to read it, and it was emailable)
  2. edit a photo of signature in gimp (nice video http://youtu.be/efAOsvfi4sU)
    1. layer/transparency/add alpha channel.  like writing on an overhead slide, the checkerboard represents the background through the slide
    2. use fuzzy select tool from toolbox to select the background from the photo
    3. delete the background, should see checkerboard.  delete within loops for O, Q, etc.
    4. from brushes, select the largest black brush and set mode to overlay.  brush over the signature to darken it  to a uniform black, otherwise it looks grayish like a photo when printed.
    5. open the pdf from gimp and select the page which needs the signature
    6. use the rectangle select tool to select the area where the signature should go.  note the height and/or width of the field.
    7. go to the signature image and image/scale image.  enter either the height or width to scale to, then`edit/copy visible.
    8. go back to the pdf and right click on the rectangle and paste.
    9. export the page to pdf
  3. use pdfshuffler to replace the unsigned page with the signed page in the PDF in order.  may need pdfshuffler orig sign orig (wasn’t able to move later pages to earlier ones, but was able to delete pages).
Categories
debian

adding wireless epson workforce 633 printer

  1. add yourself to the lpadmin group using
    sudo usermod -a -G lpadmin tom
    /etc/init.d/cups restart

  2. printer should see router so connect them and get the confirmation printout which has the IP
  3. go to http://localhost:631/
  4. add printer, give 1 word for printer name. URL will be socket://IP from printout. cups already has the driver, add Epson Workforce 630
  5. lp -d printername whatever.pdf
  6. debian wiki on printing
  7. cups printing documentation
Categories
debian Uncategorized

copy audio cd

mkdir wavdir

cdparanoia -B

cdrecord -v -audio *.wav

Categories
debian Uncategorized

copying hardlinked backups

have 2 external drives, and i use backintime to backup my main hd to one of these drives.  now i want to copy the 1st external usb drive to the 2nd, but backintime uses hardlinks, and i need to preserve these.  rsync can do it, but evidently takes a long time, so easier to use

[sourcecode lang=”bash”]

cp -avr

[/sourcecode]

sometimes the simplest solution is the best.

Categories
debian Uncategorized

mplayer mpeg stream reached EOF

make sure mariallat debian source is there, then install libdvdcss2