Elisp + Yasnippet
I keep a journal in orgmode, ok its not updated regularly but frequently enough and i use three different devices to do so. I wanted to keep track of the device used and the location in which the entry was completed, on my phone i get round the lack of an android based emacs & orgmode by using neutrinote combined with texpand and tasker to automatically populate a text file with the necessary org heading, properties and latitude/longitude (see bottom)
However using the laptop and definitely the desktop i’m sat at home so lat/lon doesnt need to be auto-updated i can simply type my location into the yasnippet template which is lucky because i havent found a way to get my lat/lon auto updated (python libraries seemed to rely on signing up for services) but i wanted the property for laptop or desktop to reflect automatically the system used. As you’ve probably guessed if you’ve looked through a few posts i like data and what i do with the properties is use a python script to create a location based heat map so i can see where i’ve been and created an entry eg;

I also use the script to see which is the most used entry method.
The yasnippet for auto update of system looks like this;
elisp code snippet start
** [`(format-time-string "%Y-%m-%d %a %H:%m")`] $0
:PROPERTIES:
`(if (string= system-name "aragorn")
":METHOD: desktop"
":METHOD: laptop")`
:PURPOSE: journal
:LOCATION: 27.997236, 86.924262
:END:
elisp code snippet end
so it uses a bit of elisp to compare the emacs variable system-name
against the host name of my desktop and then if true populates the template with :METHOD: desktop
and if not then laptop it works but this took me far longer to figure out than i had hoped :unamused: it was actually easier for me to get my phone to auto update location in a text file than the above.
OK for the phone based version this uses tasker variables to read the latitude and longitude from my phone, texpand captures these and populates the entry i create in neutrinote, it sounds complicated but its actually quite easy.
You can watch the dev’s video on how to set Tasker for Texpand here: https://www.youtube.com/watch?v=h5PVoqow4e0&feature=youtu.be
My template for texpand looks like

So basically i type jo
and texpand automatically expands this to the text above and calls on tasker to supply the contents of the variable location, simple and easy and most of all it works.