DCloud - a cloud with the UNIX philosophy
Existing cloud solutions all have issues:
- There are free services like Google, if you don’t mind them rooting through your data to learn about you.
- There are free ones like Apple, if you don’t mind your data in a walled garden with access to it only on their terms and their hardware.
- The open-source solutions are dodgy, where they exist at all.
- Paid solutions are costly.
Seeking a private, reliable, free, self-maintainable solution
for my-data-everywhere, I developed Devious Cloud. Set up a private
Subversion or Mercurial repository for your cloud. Point
Documents/Cloud on each of your machines at it. And the
cloud
command and friends do the rest.
And in case you’re away from all your machines, you can
access your data on the web, where it’s secured behind an
old-fashioned .htaccess
file.
Project status
2022–11–24 40
in development downloads addresses deprecation warnings about
timezones/localize()
and serializing in Python
3.10.
2022–09–27: r39
in development downloads removes a dependency on JQuery in the
website document index, and updates the queue2ics-produced HTML to
use <TIME>
elements rather than
<ABBR>
.
2022–07–21: r37 has been promoted to stable release.
Address Book
Although DCloud doesn’t have a formal address book format, you can keep your contacts in a plain-text file with entries separated by a blank line. There’s a remarkably utilitarian search command that’ll display matching “paragraphs”. A few aliases and you can repurpose the command for other uses. See: pn(1) man page (pdf)
$ pn winsted clerk
860-379-2713 Winsted Town Hall - vital records department (birth certificates $5)
Town Clerks Office
338 Main Street
Winsted, CT 06098
As a bonus, pn
also searches Google address books
if goobook
is installed.
Passwords
There’s a similar utility for managing passwords in an encrypted file. And it’s also easy to repurpose by wrapping it in an alias. See: pass(1) man page (pdf).
To-do lists
Make your to-do lists using Markdown’s tasks lists.
DCloud’s tasks.py
utility scans files, extracts
to-do items, and writes them in HTML with appropriate CSS-ready
mark-up. And it has options to remove complete tasks, or move them
to a separate file (with an optional date) to keep a history of
work completed. It understands subtasks, so works in progress
remain untouched until the whole job is finished. tasks(1)
[ ] This is a to-do item
[ ] Polish the cat
- [x] Acquire cat polish
- [x] Acquire cat
- [ ] Wash cat
- [ ] Get first aid
- [ ] Polish cat
[x] Tune the fish
Calendars
iCalendar (RFC 5545) is fantastic for sharing calendars, but most calendar apps are a frustrating exercise of putting data into specific fields. queue(5) format is a simple text-based machine-readable format which can be wrangled into iCalendar or HTML by queue2ics, or viewed from the command line with now(1) (pdf).
2018-05-01 Holiday Beltaine - shag like it's the first of May @ My Favorite Sex Club
2018-05-05 13:00 Sink some mayonaise @ stream out back of Discordian HQ
2018-05-09 19:00 SciFi Night - Jessica Jones @ Mike's house
2018-05-11 16:00 - 21:00 Game night @ Ye Olde Gaming Centre - Settlers with Lori and Roy
2018-05-13 17:00 Surf the web http://perette.barella.org
And just in case you want to go the other way, queue2ics can read iCalendar and write queue files.
Documents
DCloud documents are just documents in a revision control system—so not only do you get one document everywhere, you get an automatic history of changes. You can just add/modify documents using your favorite editor and revision control commands, or use the cloud(1) wrapper.
Web exports
When updates are pushed into your cloud, the server constructs a web page containing some or all your documents. Set up a web server of your own, or provide an upload script to shove the website to your hosting site. publish_cloud(1), view pictures
Technical details
DCloud is written in Korn Shell and Python 3. Perl code has been eradicated.
History & Colophon
DCloud was refined into a package as result of moving off the Mac in 2018.
pn
dates to my first UNIX machine, a second-hand
AT&T 3B1 named Unixslut, circa 1993. pass
was
developed in the late 90s or early 2000s on Selantia, a Wintel
Linux box, to deal with the quickly growing numbers of Internet
passwords around that time.
queue2ics
was originally a Perl script developed
2008ish on an iBook G4 named Mugenshi, for a file format that
evolved in the late 1990s for a TRS-80/Linux file synchronization
system. The format organizes my calendar to this day.
queue2ics
was rewritten and cleaned up in Python in
2018.
now
was originally a shell alias for tail -15
<file>
. It was replaced with a shell script that
improved formatting around 2013. Terminal-size aware behavior and
other enhancements were added in 2018.
publish_cloud.py
and tasks.py
were
both originally coded in Korn shell in 2018, but were both
rewritten to make the code more manageable. cloud
was
also written in 2018, but remains in Korn shell. All were developed
on a Thinkpad E570 named Lenora running LinuxMint 18.3 (and later
19.x), with portability testing on a mid-2009 MacBook Pro named
Stefanie running El Clownian, and server-side testing on a 2008
MacBook named Frank running Snow Leopard.
The web calendar styles, 12/24 hour time switching, and category switches were originally developed for the Rochester Kink Society website around 2009.