2014-07-27

[Technology] quotes

Another good reason to encapsulate bash variables in quotes:


If you have multilined data that you're going to echo, the quotes will preserve the newlines.




$ DATA="foo
bar";
$ echo $DATA
foo bar
$ echo "$DATA"
foo
bar
$

The first reason I tend to think of is so spaces in file names aren't mistranslated as separators between arguments.

$ FILENAME="foo bar.txt"
$ ls -l $FILENAME
ls: cannot access foo: No such file or directory
ls: cannot access bar.txt: No such file or directory
$ ls -l "$FILENAME"
-rw-rw-r--. 1 user group 0 27. Jul 18:03 foo bar.txt
$

[Technology] GNOME, missing features, and screenshots

I have been taking a lot of screen shots for a  project recently and was wondering why they weren't going into my screenshots directory.  Now I know why.



https://marteydodoo.com/writing/2013/12/15/saving-screenshots-different-directory-gnome-3/



Basically gnome-shell now handles it (which is fine) but doesn't provide an option for a directory other than your GNOME Pictures directory (not fine).   I'm not really sure why people would want to have their default images directory littered with screen shots, but whatever.




Over-riding Screenshot Keyboard Shortcuts


So, I went to Settings > Keyboard > Shortcuts

















TitleCommandKeys
Screenshotgnome-screenshotPrtSc
Screenshot of windowgnome-screenshot -wAlt-PrtSc
Screenshot of regiongnome-screenshot -aShift-PrtSc



For reasons I haven't explored yet, pressing Shift-PrtSc once doesn't trigger it, but instead sounds a bell.  Holding shift and tapping PrtSc twice quickly does, though.


Changing the Default Save Directory for Gnome Screenshot




The second half is then to make gnome-screenshot save it where I'd like it to.  Running it in interactive mode (gnome-screenshot -i) doesn't seem to give me an option on where to save it.  So, instead, I turned to gsettings.



$ gsettings set org.gnome.gnome-screenshot auto-save-directory "/home/myuser/path/to/my/screenshot/dir"

$ gsettings set org.gnome.gnome-screenshot last-save-directory "/home/myuser/path/to/my/screenshot/dir"



I don't think I need to set the second one, but I did so out of laziness.


Write a script that lets me process my screenshots


A lot of my screenshots are fine as JPGs, and save me a lot of disk space that way, so I wrote a small bash script that uses ImageMagick's convert and my 'splitalbum' to further organise them.



In the interest of getting me to publish more of my work, I automated turning little projects into tarballs and web pages and uploading them.    Here is 'Process New Screenshots', quick and dirty.



http://kosmokaryote.org/codepoems/pns/





Wait, Blogger supports having more after a break?!

2014-07-21

[Technology] More people access the Internet in China than on computers

I find that strange.



I like having a smart phone, because it helps liberate me.  I don't need to be tethered to my desk in a seated position, and I won't get super-involved in digital tasks, if I'm using my smart phone.  I can take it and just do a lot quickly and get it out of the way and resume enjoying the out doors.  Yay!



However, for doing almost anything particularly interesting with the Internet, I want a computer.  I want to be able to type efficiently.  I want to be able to see things at a larger scale.  I want to be able to be able to have multiple things open and go between them (I mean like two things for easy cross-referencing).



I'd rather get rid of my phone than my computer, I think.  The computer is a bit limiting geospatially, but he phone limits everything I could want to do digitally.

Dieses Blog durchsuchen

Labels

#Technology #GNOME gnome gxml fedora bugs linux vala google #General firefox gsoc security GUADEC android bug xml fedora 18 libxml2 programming web blogger encryption fedora 17 gdom javascript git libgdata memory mozilla open source serialisation upgrade API Spain design evolution fedora 16 fedora 20 fedora 22 fedup file systems friends future glib gnome shell internet luks music performance phone photos preupgrade tablet testing web development yum #Microblog Network Manager adb art automation bash brno catastrophe css data loss deja-dup disaster emacs emusic errors ext4 facebook fedora 19 gee gir gitorious gmail gobject google talk google+ html libxml mail microsoft mtp namespaces nautilus php picasaweb ptp resizing rpm school selinux sms speech dispatcher technology texting time management uoguelph usability video web design youtube #Tech Air Canada C Empathy Europe GError GNOME 3 GNOME Files Go Google Play Music Grimes IRC Mac OS X Mario Kart Memento Nintendo Nintendo Switch PEAP Selenium Splatoon UI VPN Xiki accessibility advertising ai albums anaconda anonymity apache apple ask asus eee top automake autonomous automobiles b43 backup battery berlin bit rot broadcom browsers browsing canada canadian english cars chrome clarity comments communication compiler complaints computer computers configuration console constructive criticism customisation dataloss dconf debug symbols debugging design patterns desktop summit development discoverability distribution diy dnf documentation drm duplicity e-mail efficiency email english environment estate experimenting ext3 fedora 11 festival file formats flac forgottotagit freedom friendship fuse galaxy nexus gay rights gdb german germany gimp gio gitlab gjs gnome software gnome-control-center google assistant google calendar google chrome google hangouts google reader gqe graphviz growth gtest gtg gtk gvfs gvfs metadata hard drive hard drives hardware help hp humour identity instagram installation instant messaging integration intel interactivity introspection jabber java java 13 jobs kernel keyboard language languages law learning lenovo letsencrypt libreoffice librpm life livecd liveusb login macbook maintainership mario memory leaks messaging mounting mouse mysql netflix new zealand nodelist numix obama ogg oggenc oh the humanity open open standards openoffice optimisation organisation package management packagekit paint shedding parallelism pdo perl pipelight pitivi privacy productivity progress progressive web apps pumpkin pwa python quality recursion redhat refactoring repairs report rhythmbox scheduling screenshots self-navigating car shell signal sleep smartphones software software engineering speed sql ssd synergy systemd tabs test tests themes thesis tracker travel triumf turtles tv tweak twist university update usb user experience valadoc volunteering vpnc waf warm wayland weather web apps website wifi wiki wireless wishes work xinput xmpp xorg xpath
Powered by Blogger.