Skip to content

yusufaktepe/c-utils

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Misc small utils, written in C

Table of Contents

net_monitor

Monitors internet connection and notifies when it's down/up.

Build:

gcc -o net_monitor net_monitor.c

noled

Turns off CapsLock LED. I'm using it to immediately turn off annoying LED whenever it's tapped/hold. (see here.)

Build:

gcc -o noled noled.c

check_fullscreen (X11)

Checks if the current window is full screen and returns true/false.

Build:

gcc -o check_fullscreen check_fullscreen.c -lX11

hotcorner (X11)

Runs a command when the mouse hits the screen corner.

Build:

gcc -o hotcorner hotcorner.c -lX11 -lXtst

Usage:

./hotcorner --top-left "notify-send 'topleft'" --top-right "notify-send 'topright'"

wmclass (X11)

Prints out window class/instance in the following format:

WM_CLASS=CLASS
WM_INSTANCE=INSTANCE

Build:

gcc -o wmclass wmclass.c -lX11

unique

Reads from stdin and outputs unique lines without sorting. (or just use: awk -v OFS="\n" '!x[$0]++')

  • Requires uthash.

Build:

gcc -o unique unique.c

About

misc small utils, written in C

Resources

License

Stars

Watchers

Forks

Languages