Showing posts with label openbox. Show all posts
Showing posts with label openbox. Show all posts

Friday, 17 January 2014

MacBook and Openbox: mimic keyboard shortcut Cmd-tab application switcher

    <keybind key="W-Tab">
      <action name="NextWindow">
        <allDesktops>yes</allDesktops>
        <finalactions>
          <action name="Focus"/>
          <action name="Raise"/>
          <action name="Unshade"/>
        </finalactions>
      </action>
    </keybind>
    <keybind key="W-S-Tab">
      <action name="PreviousWindow">
        <finalactions>
          <action name="Focus"/>
          <action name="Raise"/>
          <action name="Unshade"/>
        </finalactions>
      </action>
    </keybind>

Macbook Air and Openbox: copy the Spotlight(TM) keyboard shortcut

    <keybind key="W-space">
      <action name="Execute">
        <command>dmenu_run</command>
      </action>
    </keybind>


apt-get install suckless-tools

Sunday, 5 January 2014

Macbook Air and Openbox: Raise/Lower Volume, Up/Down Brightness

    <keybind key="XF86KbdBrightnessUp">
      <action name="Execute">
        <command>xbacklight +10</command>
      </action>
    </keybind>
    <keybind key="XF86KbdBrightnessDown">
      <action name="Execute">
        <command>xbacklight -10</command>
      </action>
    </keybind>
    <keybind key="XF86AudioRaiseVolume">
      <action name="Execute">
        <command>amixer -c 0 set Master 2dB+</command>
      </action>
    </keybind>
    <keybind key="XF86AudioLowerVolume">
      <action name="Execute">
        <command>amixer -c 0 set Master 2dB-</command>
      </action>
    </keybind>

Friday, 8 November 2013

Openbox: monitor laptop battery via CLI and notify-send


while (true);do acpi -b | perl -n -e 's/.*?(\d+)%.*/$1/;chomp;print "$_...";if ($_ <= 15) {`notify-send batalert:$_`};';sleep 180;done

Would like a beep, but can't get one, no PC speaker on MacBook Air and mplayer buffers.

Wednesday, 6 November 2013

Change X / Openbox screen brightness on CLI

  1. sudo apt-get -y install xbacklight
  2. xbacklight +10
  3. xbacklight +10
  4. xbacklight +10
  5. xbacklight -10
  6. xbacklight -10
  7. xbacklight -10

Tuesday, 6 August 2013

vncserver on Amazon Linux on Amazon's AWS

NOTE: this first step may be outdated in new versions of Amazon Linux, which provides libjpeg-turbo.

First, get a good version of libjpeg-turbo:
  1. yum clean all
  2. yum --enablerepo=amzn-preview install libjpeg-turbo
  3. see: https://forums.aws.amazon.com/thread.jspa?threadID=121128
Necessary packages:
  1. gnutls-2.8.5-10.el6.x86_64.rpm
  2. libfontenc-1.0.5-2.el6.x86_64.rpm
  3. libtasn1-2.3-3.el6.x86_64.rpm
  4. libxdmcp-1.1.1-7.ram1.x86_64.rpm
  5. libXfont-1.4.5-2.el6.x86_64.rpm
  6. libxkbfile-1.0.6-1.1.el6.x86_64.rpm
  7. libXmu-1.1.1-2.el6.x86_64.rpm
  8. mesa-dri-drivers-9.0-0.7.el6.x86_64.rpm
  9. pixman-0.26.2-5.el6_4.x86_64.rpm
  10. tigervnc-license-1.3.0-16.el6.noarch.rpm
  11. tigervnc-server-1.3.0-16.el6.x86_64.rpm
  12. tigervnc-server-minimal-1.3.0-16.el6.x86_64.rpm
  13. xkeyboard-config-2.6-6.el6.noarch.rpm
  14. xorg-x11-proto-devel-7.6-25.el6.noarch.rpm
  15. xorg-x11-xauth-1.0.2-7.1.el6.x86_64.rpm
  16. xorg-x11-xkb-utils-7.7-4.el6.x86_64.rpm
Necessary packages for fluxbox:
  1. pyxdg-0.18-1.el6.noarch.rpm
Here's a link to all the packages needed: rpms

Start by trying to install tigervnc-server. That will fail. Follow the dependencies down, installing packages one by one as they come up. If they fail, install their dependencies first.

These packages were special cases
  1. mesa-dri-drivers-9.0-0.7.el6.x86_64.rpm
    1. just "--nodeps" install this one
    2. the libraries of the dependencies are never called from my experience
  2. libXtst-1.2.1-2.el6.x86_64.rpm
    1. there is a more recent version of this already in Amazon Linux, so just skip this one and "--nodeps" the parent package, which is libXmu-1.1.1-2.el6.x86_64.rpm
If not found, add location of libXdmcp.so.6 to /etc/ld.so.conf and run "ldconfig", e.g. locations is /usr/lib/libXdmcp.so.6 so add the line "/usr/lib".

Once I got the vncserver up with

  vncserver :66 -localhost

bizarrely, it was listening on port 5966 and some 6066 port. The 5966 port is the one you want.

See previous post on Redhat VNC for details, click here.

Thursday, 25 April 2013

Quick CLI screenshots on Linux or Openbox / Fluxbox


  1. sudo apt-get -y install imagemagick eog
  2. import myscreenshot.jpg
    1. select portion of screen with the crosshairs
  3. eog myscreenshot.jpg

Monday, 17 September 2012

Anti-window, anti-desktop Linux desktop

  1. Install base debian with NO additional packages
  2. apt-get install xorg openbox obmenu slim terminator firefox wicd-gtk
  3. reboot
  4. Log in to openbox via slim
  5. Right-click on blank desktop and open default terminal
  6. Run obmenu
  7. Edit ~/.config/openbox/menu.xml to add things you like
  8. Set up network including wireless using early post on this blog
    1. It is not easy
    2. but nice to know once you learn

Interview questions: 2020-12

Terraform provider vs provisioner Load balancing Network Load Balancer vs Application Load Balancer  Networking Layer 1 vs Layer 4 haproxy u...