Skip to content

About

A background C daemon that automatically moves files from your Desktop into organized monthly folders.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Desktop Organizer

A background C daemon that automatically moves files from your Desktop into organized monthly folders. Only screenshots for now.

What it does

Runs every 8 hours and moves all files starting with Captura (macOS Portuguese) or Screenshot (macOS English) from ~/Desktop/ into:

~/Desktop/Screenshots/YYYY-MM/

Build & Run

make          # build
make run      # run (loops indefinitely in foreground)
make clean    # kill the process and remove the binary

Logic

  • Detects the current user's home directory dynamically via getpwuid
  • Creates ~/Desktop/Screenshots/ and the current YYYY-MM subfolder if they don't exist
  • Uses rename() to move matching files (no copy, instant)
  • Loops forever with an 8-hour sleep between runs (sleep(28800))

File structure

src/
  main.c                      # Entry point, loop + sleep
  desktop_screenshot_organizer.c  # Core logic
Makefile

About

A background C daemon that automatically moves files from your Desktop into organized monthly folders.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages