10pm.ca – Tidbits for the wandering Googler

bash

Simple Bash Script to Detect if Squeezeplayer is Playing or Paused

Cats: bash, command line, raspberry pi, squeezebox

By PJ on February 22, 2014


Here’s a bit of code running on my Raspberry Pi that detects if the current Squeezelite player is playing or is paused. Replace 192.168.1.10:9000 with the IP address of the server and replace 62:74:01:10:10:40 with your player ID. Note, you … Continued

Handful of Bash Scripts for Window Positioning Using wmctrl

Cats: bash, linux mint

By PJ on February 11, 2014


Centre window (with a bit of randomness, so it doesn’t perfectly overlap) centre-window.sh Two monitor setup. I have a laptop screen (1600×900) left of my main monitor (1920×1280). Change accordingly! move-to-left-monitor.sh move-to-right-monitor.sh

Bash Script: Pull the Username from the Path, or Determining Whose Home Directory We’re In

Cats: bash, command line, linux, web development

By PJ on August 1, 2013


I needed a bash script to quickly update the ownership of a bunch of files, based on what directoy I’m currently in. The username is pulled from the present working directory (pwd): /home/SOMEUSER/the/rest/of/the/path

Bash Script to Centre The Active Window for Ubuntu/Linux Mint

Cats: bash, command line, keyboard shortcuts, linux, linux mint

By PJ on June 17, 2013


I recently discovered that Linux Mint lets you use the Super/Win key plus left, right, up, down to control the current window size (window left, window right, maximize, unmaximize, respectively!), which is awesome. But I also like my windows centred … Continued

  • Newer posts →

Recent Posts

  • SpeedCrunch “Plugin”: Currency Converter
  • OctoPi/OctoPrint Change Webcam Resolution
  • Polono PL60 Label Printer on Ubuntu/Linux Mint
  • Flash Custom Firmware onto Iris v7
  • GIMP – Save for Web Plugin

Archives

  • April 2024
  • August 2023
  • July 2023
  • May 2022
  • April 2022
  • February 2022
  • August 2021
  • June 2021
  • March 2021
  • October 2020
  • April 2020
  • February 2020
  • October 2019
  • April 2019
  • March 2019
  • September 2018
  • August 2018
  • June 2018
  • May 2018
  • March 2018
  • January 2018
  • December 2017
  • March 2017
  • February 2017
  • January 2017
  • November 2016
  • September 2016
  • August 2016
  • January 2016
  • July 2015
  • March 2015
  • February 2015
  • October 2014
  • August 2014
  • February 2014
  • December 2013
  • October 2013
  • September 2013
  • August 2013
  • July 2013
  • June 2013
  • May 2013
  • April 2013
  • March 2013
  • February 2013
  • January 2013
  • December 2012

Categories

© 2025 10pm.ca – Tidbits for the wandering Googler