Closed NorfairKing closed 2 years ago
I think a workflow example of how you use smos would be invaluable. Even more valuable would be how you moved from org-mode (assuming you were once there to be motivated to make smos) to smos.
For me to be won over or won over enough to put more time into trying smos this weekend for example, that sort of information would have been most compelling.
@codygman I agree that this would be great. I'm having a hard time striking the balance between re-explaining all of GTD and just assuming that the reader knows GTD. In any case, it will take a bit of time until I can get those blogposts out, so in the meantime: If you'd like to try out smos, we could set up a call and I could walk you through it if you'd like.
I recently remembered this and became interested again. I can't do it within the next few weeks, but I'll schedule thinking about scheduling a call or sorting something out with you!
Yes please!
@NorfairKing, can we pick up the conversation from https://github.com/NorfairKing/smos/pull/39#issuecomment-621724471 here? I'd prefer GitHub versus email so that more people have access to your responses & this is one of the first places I stumbled into when looking for more smos workflow/tutorial information.
If we're going to do a smos-measuring contest, I'll win :p
22.5k tasks! How many files is that split over? I'm trying to get a feel for how large or small individual project files should be.
The annoying part is that all the DONE tasks start cluttering everything up, but I want to keep their history around instead of just deleting things.
Yes, that's a good reason to put things in separate files and then using smos-archive.
Do you have any utility scripts, functions, or aliases for making project file management easier? Probably my biggest hangup is losing the easy access to everything I have w/ a single big file. In my perfect world, I'd have tab completion for the files in my worflow-dir
and projects-dir
.
Side note: will smos use a custom workflow-dir
as the base for the archive/projects/projects-archive directories? Or do I need to set those as well? (I've been using ~/.tasks/
as my workflow dir, with absolute paths for the other options set to their default suffix like ~/.tasks/archive
).
Currently I have put a task in my weekly review template (that I copy around during the previous weekly review) to create a project to pay my bills (from another template). So I'd have bills-17.smos for the bills project of the 17th week of the year.
I'd love to learn more about templates, either here or in your future posts. I found #25 which gives a sample of a template file, but I'm not sure how a file is picked for generation, what levers are available for tweaking, what is available for interpolation, etc.
I eagerly await reading about your weekly review template, I haven't gotten to formulating a weekly review process yet.
@NorfairKing, can we pick up the conversation from #39 (comment) here? I'd prefer GitHub versus email so that more people have access to your responses & this is one of the first places I stumbled into when looking for more smos workflow/tutorial information.
If we're going to do a smos-measuring contest, I'll win :p
22.5k tasks! How many files is that split over? I'm trying to get a feel for how large or small individual project files should be.
They're mostly in the archive. Individual projects are <20 entries on average.
The annoying part is that all the DONE tasks start cluttering everything up, but I want to keep their history around instead of just deleting things.
Yes, that's a good reason to put things in separate files and then using smos-archive.
Do you have any utility scripts, functions, or aliases for making project file management easier? Probably my biggest hangup is losing the easy access to everything I have w/ a single big file.
smos-query
does most of what I want.
What kind of overview/access do you still need?
Does the interactive next-action report help?
In my perfect world, I'd have tab completion for the files in my
worflow-dir
andprojects-dir
.
I'd like that too. I think it could be possible as well. We can implement completion from Haskell but we need to think about the way that should work.
Side note: will smos use a custom
workflow-dir
as the base for the archive/projects/projects-archive directories? Or do I need to set those as well? (I've been using~/.tasks/
as my workflow dir, with absolute paths for the other options set to their default suffix like~/.tasks/archive
).
Smos uses paths relative to the workflow dir by default.
See Smos.Report.Config
.
Currently I have put a task in my weekly review template (that I copy around during the previous weekly review) to create a project to pay my bills (from another template). So I'd have bills-17.smos for the bills project of the 17th week of the year.
I'd love to learn more about templates, either here or in your future posts. I found #25 which gives a sample of a template file, but I'm not sure how a file is picked for generation, what levers are available for tweaking, what is available for interpolation, etc.
I eagerly await reading about your weekly review template, I haven't gotten to formulating a weekly review process yet.
Getting the template in the right place is just done with cp
. Nothing high-tech.
What to put in the weekly review template is very personal but I will be writing about it a bit more in the future.
If you email me about this, I can give you access to my drafts so you can review the blogposts if you'd like.
smos-query does most of what I want. What kind of overview/access do you still need?
Hmm, after checking out the interactive next report, I guess most useful would be for creating new project files. I might look into adding directory completion to something like this:
# smosp - start a new smos project file with a single task
smosp() {
PROJECT_FILE="$1"
TASK="${@:2}"
smos-single --file "~/.tasks/projects/${PROJECT_FILE}" $TASK
}
& maybe something similar for archiving projects.
I think once the files are made I can use the interactive reports for navigation
Does the interactive next-action report help?
I'm going to start playing around with multiple files and the interactive report and see if that resolved my navigation woes.
I use these, but they still don't give me autocompletion:
# Open with smos
note_ () {
local dir="$1"
local id="$2"
file="$HOME/workflow/$dir/$id.smos"
sm "$file"
}
alias n='note_ projects'
alias b='note_ batch'
alias r='note_ reference'
alias s='note_ someday'
# Open with vim
note_vim_ () {
local dir="$1"
local id="$2"
file="$HOME/workflow/$dir/$id.smos"
v "$file"
}
alias nv='note_vim_ projects'
alias bv='note_vim_ batch'
alias rv='note_vim_ reference'
alias sv='note_vim_ someday'
alias sq='smos-query'
alias sa='smos-archive'
archive_ () {
local dir="$1"
local id="$2"
file="$HOME/workflow/$dir/$id.smos"
sa "$file"
}
alias a='archive_ projects'
alias next='sq next'
alias wait='sq waiting'
alias agenda='sq agenda'
alias clock='sq clock'
alias sa='smos-archive'
alias projects='sq projects'
alias sw='smos-query work'
alias wh='sw home'
alias wp='sw plug'
alias wt='sw transport'
alias wa='sw airplane'
I messed around w/ writing zsh completions for some functions I wrote:
# start a new smos project file with a single task
function smosnp() {
PROJECT_FILE="$1"
FULL_PATH="${HOME}/.tasks/projects/${PROJECT_FILE}"
TASK="${@:2}"
if [ ! -e "${FULL_PATH}" ]; then
smos-single ${TASK} --file "projects/${PROJECT_FILE}"
fi
smos "${FULL_PATH}"
}
function _smosnp() {
_arguments "1:directory:_path_files -/ -W \"${HOME}/.tasks/projects/\""
}
compdef _smosnp smosnp
# open the given project file in smos
function smosp() {
PROJECT_FILE="$1"
FULL_PATH="${HOME}/.tasks/projects/${PROJECT_FILE}"
smos "${FULL_PATH}"
}
function _smosp() {
_arguments "1:file:_path_files -W \"${HOME}/.tasks/projects/\""
}
compdef _smosp smosp
# open the given task file in smos
function task() {
TASK_FILE="$1"
FULL_PATH="${HOME}/.tasks/${TASK_FILE}"
smos "${FULL_PATH}"
}
function _task() {
_arguments "1:file:_files -W \"${HOME}/.tasks/\""
}
compdef _task task
# archive the given task file
function archive() {
TASK_FILE="$1"
FULL_PATH="${HOME}/.tasks/${TASK_FILE}"
smos-archive "${FULL_PATH}"
}
function _archive() {
_arguments "1:file:_files -W \"${HOME}/.tasks/\""
}
compdef _archive archive
Essentially, task
& archive
will complete any file/folder in my workflow dir, smosnp
will complete any folders in my projects dir, & smosp
will complete any file or folder in my projects dir.
I used these guides to learn just enough to get what I want out of this: https://github.com/zsh-users/zsh-completions/blob/master/zsh-completions-howto.org http://zsh.sourceforge.net/Doc/Release/Completion-System.html#Completion-Functions
This could be made even more generic by using yq to grab the workflow-dir:
$ yq -r '.["workflow-dir"]' ~/.config/smos/config.yaml
/home/prikhi/.tasks
@prikhi That's really cool! I've improved the docs a lot: https://smos.cs-syd.eu . Please have a look and let me know what you think.
It looks great! The action reference & the config reference for smos-query commands is very helpful. My first run-through, I kind of wished there were next & previous buttons at the bottom of the page, but after that, I pretty much know where I want to jump to.
There's now a playground.
There is already a
tutorial.smos
file in the root dir, but this should be expanded to be something likevimtutor
.