Jarek
-
Posts
34 -
Joined
-
Last visited
-
Days Won
2
Content Type
Blogs
Gallery
Downloads
Events
Profiles
Forums
Articles
Media Demo
Posts posted by Jarek
-
-
14 hours ago, drwatson said:
It was a bit hard finding the alfred since it was baked into the sourcecode zip this time FYI
Indeed, somehow it was missing on the releases page. Re-uploaded now: https://github.com/jaroslawhartman/TimeZones-Alfred/releases (scroll down to
-
-
v2.16, 16 August 2020
- #35 Pull Request Fix incorrect City -> Country mapping
- Converted time copied to Clipboard after hitting Enter
- #36 Added hybrid time format: 24hr (12hr), i.e. 14:30 (2:30 pm). Change using 'timezone both'
- #22, #25: Support for UTC timezone (timezone add utc)
https://github.com/jaroslawhartman/TimeZones-Alfred/releases
-
11 hours ago, bivalvegruff said:
I'm missing the flag for Åland, I noticed it's not in the free country flags website. Åland belongs to Finland, but is an autonomous province (with its own flag). Would it be possible to add their flag, or if not, have it represented by the Finnish flag rather than by the question mark flag? Thanks!
Try v2.15:
-
I think problems with moving the configuration (e.g. to a Dropbox folder) are fixed now in v2.14. Give a try; just in case - make a copy of your timezones.txt!
https://github.com/jaroslawhartman/TimeZones-Alfred/releases
-
13 hours ago, deanishe said:
But this hasn't really been a problem for anyone before, so is your workflow really that special?
6 hours ago, drwatson said:this seems like an unnecessary question. If I had to guess, it's because Jarek inherited the code from someone else. He's done a great job. I'd leave it at that.
I don't take it personally. I don't think this workflow is special in any way. But it was even admitted in your response to mu question, that there are no official guidelines how to treat workflow preferences to make them mobile across different devices. However, I like the suggestion provided there, will try to implement.
Best regards,
Jarek
-
Thank you for the response. I like your idea with ../com.example.my-workflow-data . Will give a try.
Best regards,
Jarek
-
52 minutes ago, deanishe said:
Save the file in $alfred_workflow_data, like you're supposed to. As noted above, this will never change again.
The script is using this variable even now. Problem with this setup is that there is no link between value of this variable and your Advanced | Set preferences folder . I was assuming that once changing the preference folder, the $alfred_workflow_datawill be also changed - but it's not. My bad, will need to rectify it.
Best regards,
Jarek
-
7 minutes ago, drwatson said:
Also, if you still want to keep it for backwards compatability, you could use the info.plist to store a reference to the location of the file instead.
That's exactly the workaround I was thinking of 🙂
-
-
Hi,
I'd expect that after changing my preferences folder, it will also affect location of the workflows (including their working directories). But somehow it only affects location of the Alfred.alfredpreferences
But it does not change Workflow Data location. Here an example:
- In my workflow, I use these two variables. Below values when using a default location:
alfred_workflow_data /Users/jhartman/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones2 alfred_preferences /Users/jhartman/Library/Application Support/Alfred 3/Alfred.alfredpreferences
- After changing Preferences Folder:
alfred_workflow_data /Users/jhartman/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones2 alfred_preferences /Users/jhartman/Downloads/Alfred/Alfred.alfredpreferences
As you can see, still points to the old location.
Edit I think bottom question is: how to handle custom workflow preferences to allow them being synchronised across different laptops, alongside Alfred preferences?
To me it somehow invalidates the idea of syncing the configuration? Or em I missing something?
Thank you,
Jarek
---------------
Alfred 3.8.2 Build 963, Friday 31st May 2019
MacOS 10.14.6 (18G87)
Can be consistently reproduced
-
7 minutes ago, drwatson said:
- The preference folder as determined in Advanced | Set preferences folder
- The storage location as defined within the timezone script itself (timezone move command).
Right now, it doesn't appear to honor either
I think the (1) still works, as the location set by Set Preferences Folder should be reflected as $alfred_workflow_data variable (which is in use).
Indeed, there is a regression in (2) - the Move command does not work anymore. Registered as https://github.com/jaroslawhartman/TimeZones-Alfred/issues/23 . Will try to prioritise.
Best regards,
Jarek
-
6 minutes ago, drwatson said:
Jarek: I noticed that the workflow doesn't save the timezone.txt file to the correct location anymore. Any chance you could look into that ?
Could you please elaborate what do you mean by correct location?
Indeed, there was a change a few releases back and it was related to Alfred 4. Instead of having a hardcoded path, it uses now alfred_workflow_data variable.
On my Mac it's /Users/jhartman/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones2:
jhartman$ cd "/Users/jhartman/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones2" jhartman$ ls -l total 16 -rw-r--r--@ 1 jhartman staff 26 Aug 14 14:48 configExtra -rw-r--r-- 1 jhartman staff 369 Aug 14 15:04 timezones.txt
Best regards,
Jarek
-
17 minutes ago, deanishe said:
That line should be sortkey=$(printf "%03d" $(( 10#$sortkey + 1 )))
The 10# tells bash to interpret the numbers in base 10.Thank you for troubleshooting and suggesting a fix. I've included it in the branch and released v2.13
It can be downloaded from https://github.com/jaroslawhartman/TimeZones-Alfred/releases
Best regards,
Jarek
-
Hi,
Latest version can be downloaded from:
- https://github.com/jaroslawhartman/TimeZones-Alfred
- https://jhartman.pl/tag/alfred/
- http://www.packal.org/workflow/timezones-2
At time of writing, v2.6 is the latest.
Best regards,
Jarek
-
New version 2.4 has been released. You can pin your favourite locations to the top of the list: press Enter while holding Command key:
-
On 10/22/2018 at 5:03 PM, JQuinn said:
One quick question, in the original version I believe you can do a quick search on any city's time with below;
tz *city*
Is that still available now? I didn't see it in the workflow scripts, but maybe I missed the prompt ¯\_(ツ)_/¯
I would like to search for a random city without adding it to the cities list.
Good point. Seems it has been regressed during one of the updates.
I will take a look; to have it on the radar created GitHub ticket in https://github.com/jaroslawhartman/TimeZones-Alfred/issues/6
Thank you and best regards,
Jarek
PS: A new version 2.1 has been created to remove dependency on Growl and improve (I hope!) adding new cites via timezone add
-
Hi Eric,
Well spotted! It's fixed now.
BTW: the list in version 2.0 is always sorted alphabetically. Please let me know if this is something useful.
Thank you,
Jarek
-
Hi,
I think I've managed to fix the workflow and adding new cities is possible again!
More changes:
- Added a keyword to open list of the cities in an editor _timezone edit. Thanks to that you will be able to quickly delete not needed lines.
- When displaying the list and pressing Alt, you can remove a single city (this is fixed now)
Unfortunately, you will need to create your list of cities again... But this will also clean up your list as in previous version it got messed up.
I hope you will like it Note, that major parts of the app have been rewritten so I could expect also new bugs... Please let me know in such cases.
Best regards,
Jarek
-
Hi,
This is actually an issue, and this is pretty serious:
QuoteKeyless access to Google Maps Platform is deprecated. Please use an API key with all your API calls to avoid service interruption. For further details please refer to http://g.co/dev/maps-no-account
In a short - it's caused by Google, who disabled charge-free access to their services.
I'd have to find an other (free) service to provide an API to lookup for Time Zone details based on Geographical location.
Until then, adding new city or update timezones will not work ? As a workaround, add a line with Boston to the config file. Open in terminal
$ open -a /Applications/TextEdit.app "$HOME/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones/timezones.txt"
Add a line like:
Dubai|Dubai|United Arab Emirates|25.2048493|55.2707828|14400|Asia/Dubai|Gulf Standard Time|UTC+4||971
Best regards,
Jarek
-
5 hours ago, ericb said:
I just installed v1.7 with Alfred 3 and could not get any timezones to list. Even the default ones. It seems the scripts were looking for an Alfred 2 directory that I didn't have. I created a symbolic link called Alfred 2 to Alfred 3 and now things are working. I'm surprised I had to make this change though so I'm wondering if there is something else wrong.
/Users/eric/Library/Application Support/Alfred 3
/Users/eric/Library/Application Support/Alfred 2
Eric
Hi Eric, try version 1.9 from https://jhartman.pl/2017/05/04/timezone-v1-9/
Best regards,
Jarek
-
Hi Miguel,
The problem is happening around these lines:
++ curl --connect-timeout 10 -s 'https://maps.googleapis.com/maps/api/timezone/xml?location=25.2711390,55.3074850×tamp=1524754016&sensor=false' + api_timezone= + OIFS=' ' + IFS=' ' ++ php parsexml_timezone.php ''
As you see, whenever attempting to read the timezone details from the web, curl command does not return any data.
I'm guessing it's exactly because of your VPN and the way, how it allows to access the Internet. Most likely, it requires a proxy. Run two tests pls:
a) Open this page in a web browser (e.g. Safari or Chrome)
https://maps.googleapis.com/maps/api/timezone/xml?location=-36.8484597,174.7633315×tamp=1524754015&sensor=false
b) run this in Terminal
curl --connect-timeout 10 -s 'https://maps.googleapis.com/maps/api/timezone/xml?location=-36.8484597,174.7633315×tamp=1524754015&sensor=false'
Both should generate similar results, but I'm afraid the second returns just nothing.
If this is really because of the proxy, in a first step you would need to find out what the proxy is (this depends on you VPN provider or your IT). Then, let's make a test in Terminal:
export http_proxy=http://<proxy>:<port>/ curl --connect-timeout 10 -s 'https://maps.googleapis.com/maps/api/timezone/xml?location=-36.8484597,174.7633315×tamp=1524754015&sensor=false'
Of course, you need to change http://<proxy>:<port>/ into legit proxy URL.
If this time curl will return something like below:
<?xml version="1.0" encoding="UTF-8"?> <TimeZoneResponse> <status>OK</status> <raw_offset>43200.0000000</raw_offset> <dst_offset>0.0000000</dst_offset> <time_zone_id>Pacific/Auckland</time_zone_id> <time_zone_name>New Zealand Standard Time</time_zone_name> </TimeZoneResponse>
Then fixing will be as easy as updating includes.sh by adding the line below:
#includes for TimeZones scripts #Working Directories TZWD="$HOME/Library/Caches/com.runningwithcrayons.Alfred-3/Workflow Data/carlosnz.timezones" TZPREFS="$HOME/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones" CONFIG_EXTRA="$TZPREFS/configExtra" export http_proxy=http://<proxy>:<port>/ #### ADD THIS LINE WITH PROPER PROXY DETAILS
I hope it will help.
Jarek
PS: The log you posted above is quite long, perhaps you may want to remove it from the forum and post to e,.g. https://justpaste.it/
-
Hi Miguel,
QuoteI already uncommented everything on the add city file and the timezone update and here is what i notice
Could you please revert to the original versions and give me output from these commands.
Go to the Workflows and select Open in Terminal:
Then type copy and paste these lines and paste here the output:
cat "$HOME/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones/timezones.txt"
cat "$HOME/Library/Application Support/Alfred 3/Workflow Data/carlosnz.timezones/configExtra"
Then run:
sh -x update.sh > ~/Desktop/Update.txt 2>&1
This will provide a lot of output
This should create file Update.txt on your desktop - please post it here as well.
Thanks and best regards,
Jarek
-
In fact, 24h format has been hardcoded into version I've tailored from CarlosNS' version. This has been updated in v1.9 which can be downloaded from http://jhartman.pl/download/alfred-timezone-workflow/
Format cab be chosen using keywords 'timezone 24h' and 'timezone 12h':
Best regards,
Jarek
Alfred should show its window in active display, accordingly to mavericks
in Alfred Feature Suggestions
Posted · Edited by Jarek
Is this still working in Alfred 5? Can't find this option in 5.0.2.
Regards!
----
Self update: Found it! However it was not easy... also - these options are not found through "Search Preferences" textbox.