Jump to content


  • Content Count

  • Joined

  • Last visited

Everything posted by Bhishan

  1. Thanks for instructing me how to report the crashes: 1. I am very unfamiliar with Mac OS app development. Currently I am using Alfred in my Laptop (Mojave). Alfred has crashed few times in last few weeks (may be once or twice but not much). I looked at Console.app but I am not sure how to find the App specific log files. There are folders like a. ~/Library/Logs b. /Library/Logs and c. /var/log. I looked inside them and did not find any folder named Alfred, so I am not sure how to find the related log file of Alfred. 2. The alfred crashes in my office computer (Yosemite) when I run Markdown TOC (http://www.packal.org/workflow/markdown-toc) on large github markdown file (not much large, just about 50 headers). But the workflow runs good in Mojave. I have experienced Alfred crashing multiple time crashing in Yosemite when using that workflow. Also, I had lots of snippets 2000 (latex snippets) + 2000 (other snippets) = 4k snippets. And when using text expansion, I have seen Alfred crashing in Yosemite. So, I moved all snippets from Alfred to aText. Now When I click Features/Snippets in Alfred it opens much quickly in both Yosemite and Mojave. Previously it would take me about a minute to open just the window. I also cleaned not used Alfred Workflows and backed them for future use if ever wanted. Now Alfred opens fast and I have not seen crashes yet. (Its been two days). 3. Talking about cleaning app, I use Google chrome extension Click&Clean so many times whenever there are caches or browser histories accumulated. To clean the Mac, I use Dr. Cleaner everyday. But I use Dr. cleaner only in my laptop, its not been installed in office computer where the Alfred crashes much often. Now, after crashing Alfred, I have moved all snippets out of Alfred and use another text expansion software aText. and also cleaned currently not used Workflows. I have not see any crashes. If I see any crashes I will post Console.app log files.
  2. Date: July 10, 2019 Alfred version: 4.0.2 MacOS: 10.10.5 (Yosemite) I just wanted to report the bug that Alfred4 keeps shutting down on itself when I am trying to invoke some snippet expansions or use some workflow on MacOS Yosemite. I am using Alfred in Yosemite in office computer and use it everyday. In every few days ( one or two days in week) Alfred keeps shutting down without doing anything and it also takes long time to start on. I have lots of workflows (about 200) and many snippets (~MB) and application size may be the issue but I am experiencing this problem more often in Yosemite than in Mojave (my laptop). I use office computer much more than my laptop that may be the reason but Alfred also crashes in Mojave ones in few days. I am not sure if there are any log files if the app Alfred crashes automatically and if there are any I would be happy to report it. Hope upcoming updates/versions will be more robust to workflow sizes and stop crashing on its own.
  3. I have found this workflow very useful. For example: In github commit the edited file: document.getElementById('submit-file').click();. I am totally unfamiliar with javascript, Is there also an option to "EDIT" the file in github? If so what would be the command? Help is highly appreciated. P.S. Where can I find some commands like: document.getElementById('submit-file').click();. online ? These commands are new to me.
  4. I have been experiencing this problem for little a while. Whenever I try to edit the Utility "Split Arg to Vars" can only cancel it but can not save it at all. How can I edit the delimiter in this args to vars utility? Date: Jun 29, 2019 Alfred version: 4.0 user: bp959314@ohio.edu
  5. Thanks @deanishe , I had just found the mistake this morning 4 hours after you posted the solution, but without looking the solution. I was trying to find out why it was not working and did this echo "$1" "$pwd" > a.sh and looked inside a.sh, it showed an unwanted new line was there and I fixed that by changing echo by echo -n . Then I checked my Alfred thread, there was the same suggestion already. Thanks anyways.
  6. I was developing a simple workflow to copy/move the latest file or folder in Downloads to the current working directory. I have almost completed the workflow but the Alfred debugger is giving me this error consistently: ": No such file or directory" Even though the same command works in terminal. Here is the workflow I have done so far: https://github.com/bhishanpdl/Shared/blob/master/Alfred_questions/aa Copy Last Download to PWD.alfredworkflow?raw=true How to fix the problem. What I am trying to do is given below: #================ # example # # echo "hello" > ~/Downloads/a.txt # cat ~/Downloads/a.txt # # mkdir -p ~/try\ space # create a directory with space in it # cd ~/try\ space # # open . # this opens the Finder where we want to test our workflow # # command to test: # /bin/mv ~/Downloads/a.txt ~/try\ space/ # this works in terminal # # but does not work in Alfred.
  7. This was a very interesting workflow. But the API has been changed and the workflow in not working anymore.
  8. @xilopaint Thanks, that fixed my problem for Alfred 4.
  9. Does not work with online search for Alfred 4.0. [18:05:28.890] Logging Started... [18:05:30.309] Get App Icon [1.5][Script Filter] Queuing argument 'pastebin' [18:05:30.412] Get App Icon [1.5][Script Filter] Script with argument '(null)' finished [18:05:30.415] Get App Icon [1.5][Script Filter] <?xml version="1.0"?><items> <item> <arg>online^pastebin</arg> <title>Search app icons online</title> <subtitle>Switch to online search in App Store and Mac App Store</subtitle> </item> <item> <arg></arg> <title></title> <icon type="fileicon"></icon> </item> </items> [18:05:34.789] Get App Icon [1.5][Script Filter] Processing complete [18:05:34.797] Get App Icon [1.5][Script Filter] Passing output 'online^pastebin' to Run Script [18:05:34.991] ERROR: Get App Icon [1.5][Run Script] 35:44: syntax error: A “"” can’t go after this identifier. (-2740)
  10. The app Numi works but the Alfred workflow does not work. Alfred workflow: http://www.packal.org/workflow/numi Numi: http://numi.io/static/dev/Numi.zip ERROR: Numi[Script Filter] Code 1: index.js:120:158: execution error: Error on line 5: Error: Application can't be found. (-2700)
  11. To get the value of "e" you may want to type =exp(1) The imaginary number "i" is not supported in Alfred 4. You can visit the calculator settings here: https://www.alfredapp.com/help/features/calculator/ If you want to use the math libraries of python (math, numpy) you can use this workflow: http://www.packal.org/workflow/python-interpreter Then, pt e**(1j*pi) Gives: (-1+1.2246467991473532e-16j) pt real(e**(1j*pi)) Gives -1. NOTE: 1. In python 1j is imaginary number 1i. 2. In python power operation is **
  12. I have set up a simple workflow to create a new file from the clipboard into the frontmost finder item, but somehow it appends "?" sign in front of the file name. When I output LARGE TYPE, there is no "?" sign prepended, but when I write something it is prepended. How this can be fixed? I have shared workflow in Github: https://github.com/bhishanpdl/Shared/blob/master/Alfred_questions/New File from Clipboard.alfredworkflow?raw=true I am using Write Text File Aflred object with file path as {query}.
  13. If you are a STEM student, you might have been familiar with the markup language LaTex. Typing equations in LaTex is painful and it is almost impossible to compile the latex document without getting an error once or twice. To facilitate writing LaTex documents, I have created a comprehensive (more than 2000) snippets especially dedicated to latex greek letters. Example usage: Type this: \\a This expands to: \alpha Type this: \\ax This expands to: $\alpha$ and so on. Here: prefix = \\ letter = a expands to = alpha The snippet can be found in my GitHub: https://github.com/bhishanpdl/ALFRED/blob/master/AlfredSnippets/LatexGreek.alfredsnippets Installation: 1. Download the snippet and double click 2. UNCHECK the option Strip snippet of auto expand flag (by default it is checked, uncheck it) Detailed usage: Some rules: 1. I call Partial, Angle and Bold as prefix terms. 2. I call other attributes such as bar, prime, hat, etc suffix. 3. x means surround by the two dollar sign. E.g to create $\alpha$ we need to type \\ax. 4. suffix attributes need only one extra letter at the beginning. Eg. to create \bar{\alpha} we need to type \\ab` where b means bar. 5. prefix attributes needs two surrounding letters. E.g. to create \partial{\alpha} we need to type \\pay here prefix p means partial and we also need last letter y.
  14. Sadly None of the versions of QLcolorcode worked for me. Still gives the same error. https://github.com/BrianGilbert/QLColorCode-extra https://code.google.com/archive/p/qlcolorcode/downloads Thanks though.
  15. This does not work on Alfred 3. Tested: May 11, 2019 Error: Workflow incompatible. Please update to the latest version of Alfred. Also, tried FIXUM, but still does not work.
  16. Thanks for the idea of converting markdown to bbcode
  17. One more Aside: How to hightlight just a word here in this Alfred Forum? I tried backticks like in markdown: `highlight me`, but it does not highlight here in this forum. For example how to highlight the word: APPLESCRIPT ?
  18. $ ls ~/Library/QuickLook/ color.zip BetterZipQL.qlgenerator/ QLFits3.qlgenerator/ QLStephen.qlgenerator/ Readme.txt QLColorCode.qlgenerator/ QLMarkdown.qlgenerator/ QuickLookJSON.qlgenerator/ $ ls /Library/QuickLook/ iBooksAuthor.qlgenerator/ iWork.qlgenerator/ I have installed some plugins in the path `~/Library/QuickLook/`. I suspect these are causing the problems. Temporarily, I backed all the plugins and reset it. cd ~/Library/QuickLook/ cp * ~/Dropbox/quicklook_backup pwd # WARNING: be sure you are at correct folder sudo rm -rf * qlmanage -r qlmanage -r cache cd ~/tmp qlmanage -p a.sh # now, despite permission error it shows the quickview. # this solves the problem, we can use qlmanage from terminal and alfred workflow also works. # but i dont want to delete all the plugins, especially the plugin qlcolorcode. But, I like to use the plugin QLColorCode.qlgenerator, it makes the quick view of scripts syntax highlighted, but on the other hand causes qlmanage to fail. Still, when I select a file in Finder and hit space, it gives syntax highlighted quick view. I am indifferent to command `qlmange -p` fail or pass, I would be happy to use the color highlighted preview of scripts on my Finder. So, I was looking for help with `APPLESCRIPT` where we can simulate keystroke `select file and hit cmd y or hit space`. If some developers have an idea of AppleScript, I would seek their help and greatly appreciate their effort.
  19. 1. I forgot to post the error code and instead pasted the screenshot, with apologies, I have included the error log for the command of `qlmanage -p a.sh` $ /usr/bin/qlmanage -p a.sh Testing Quick Look preview with files: a.sh 2019-05-11 12:43:43.026 qlmanage[2234:143427] *** CFMessagePort: bootstrap_register(): failed 1100 (0x44c) 'Permission denied', port = 0x933f, name = 'com.apple.coredrag' See /usr/include/servers/bootstrap_defs.h for the error codes. Segmentation fault: 11 2. the error log says look at `/usr/include/servers/bootstrap_defs.h` but there is no directory called 'include' inside '/usr' and hence no file `bootstrap_defs.h`. 3. `qlmanage -p -d1 a.sh` full error log: Process: qlmanage [3157] Path: /usr/bin/qlmanage Identifier: qlmanage Version: 775.5 Code Type: X86-64 (Native) Parent Process: bash [2174] Responsible: qlmanage [3157] User ID: 501 Date/Time: 2019-05-11 14:47:34.063 -0400 OS Version: Mac OS X 10.14.4 (18E226) Report Version: 12 Bridge OS Version: 3.0 (14Y677) Anonymous UUID: 7DE74171-844A-93C0-0F1A-0107803E2F17 Sleep/Wake UUID: 85F49D0C-EF83-49C5-9B22-6AA6573AB534 Time Awake Since Boot: 14000 seconds Time Since Wake: 3900 seconds System Integrity Protection: enabled Crashed Thread: 0 Dispatch queue: com.apple.main-thread Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000020 Exception Note: EXC_CORPSE_NOTIFY Termination Signal: Segmentation fault: 11 Termination Reason: Namespace SIGNAL, Code 0xb Terminating Process: exc handler [3157] VM Regions Near 0x20: --> __TEXT 000000010169e000-00000001016f7000 [ 356K] r-x/rwx SM=COW /System/Library/Frameworks/QuickLook.framework/Versions/A/Resources/quicklookd.app/Contents/MacOS/qlmanage Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 com.apple.WebKit 0x00007fff4e63d472 WebKit::ChildProcessProxy::state() const + 4 1 com.apple.WebKit 0x00007fff4e77389e WebKit::NetworkProcessProxy::removeSession(PAL::SessionID) + 26 External Modification Summary: Calls made by other processes targeting this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by all processes on this machine: task_for_pid: 8703 thread_create: 0 thread_set_state: 0 VM Region Summary: ReadOnly portion of Libraries: Total=516.6M resident=0K(0%) swapped_out_or_unallocated=516.6M(100%) Writable regions: Total=1.1G written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=1.1G(100%) VIRTUAL REGION REGION TYPE SIZE COUNT (non-coalesced) =========== ======= ======= Accelerate framework 256K 2 Activity Tracing 256K 1 CG image 1028K 1 CoreGraphics 8K 1 CoreUI image file 224K 6 Dispatch continuations 8192K 1 Foundation 4K 1 JS JIT generated code 1.0G 3 Kernel Alloc Once 8K 1 MALLOC 52.7M 28 MALLOC guard page 32K 8 SQLite page cache 64K 1 STACK GUARD 56.0M 6 Stack 10.5M 6 VM_ALLOCATE 140K 8 WebKit Malloc 4216K 5 __DATA 43.1M 366 __FONT_DATA 4K 1 __GLSLBUILTINS 5176K 1 __LINKEDIT 221.6M 6 __TEXT 295.0M 368 __UNICODE 564K 1 mapped file 45.4M 16 shared memory 676K 11 =========== ======= ======= TOTAL 1.7G 849 Model: MacBookPro14,2, BootROM, 2 processors, Intel Core i7, 3.5 GHz, 16 GB, SMC 2.44f1 Graphics: kHW_IntelIrisGraphics650Item, Intel Iris Plus Graphics 650, spdisplays_builtin Memory Module: BANK 0/DIMM0, 8 GB, LPDDR3, 2133 MHz, 0x802C, 0x4D5435324C31473332443450472D30393320 Memory Module: BANK 1/DIMM0, 8 GB, LPDDR3, 2133 MHz, 0x802C, 0x4D5435324C31473332443450472D30393320 AirPort: spairport_wireless_card_type_airport_extreme (0x14E4, 0x171), Broadcom BCM43xx 1.0 ( AirPortDriverBrcmNIC-1305.8) Bluetooth: Version 6.0.11f4, 3 services, 27 devices, 1 incoming serial ports Network Service: Wi-Fi, AirPort, en0 USB Device: USB 3.0 Bus USB Device: USB2.0 Hub USB Device: USB 2.0 Hub USB Device: Keyboard Hub USB Device: Apple Optical USB Mouse USB Device: Apple Keyboard USB Device: USB 2.0 BILLBOARD USB Device: iBridge USB Device: USB3.0 Hub Thunderbolt Bus: MacBook Pro, Apple Inc., 39.2 Thunderbolt Bus: MacBook Pro, Apple Inc., 39.2 4. Also, since qlmanage is not working, an alternative might also be using applescript and avoiding qlmanage altogether.
  20. # Given solution works in office compute but does not work in my laptop Office computer: macos Yosemite, clean nothing quickview qlgenerators installed Laptop: macos mojave and some quickview qlgenerators installed (eg. QLColorcode) - /usr/bin/qlmanage -p a.pdf # it works despite some warnings - /usr/bin/qlmanage -p a.sh # it does not work (qlmanage fails) - NOTE: hitting space on a.sh works on finder - NOTE: hitting cmd-y on a.sh works on finder That is why I was looking a way using "APPLESCRIPT". I am hardly familiar with AppleScript, but I feel I was pretty close to the solution in the third part of the applescript workflow in my question.
  21. I am attempting to create a workflow that pastes the contents of clipboard to a file and opens that file using QuickView. The simpleset approacth would be `qlmange -p myfile.ext`, but for some reasons my computer is not working `qlmanage -p ` command and I have to use `applescript`. Here is link of my workflow: https://github.com/bhishanpdl/Shared/blob/master/Alfred_questions/aa Clipboard QuickView.alfredworkflow?raw=true Here is outlook of my workflow: # part1: Keyword # part 2: Bash # if argument exist if [[ $# -gt 0 ]] ; then OUT="a.$1" fi # if arg doesnot exist if [[ $# -eq 0 ]]; then OUT="a.py" fi pbpaste > ~/Dropbox/$OUT echo -n "~/Dropbox/$OUT" # part3: Applescritpt property folderPath : "/Users/poudel/Dropbox" on run {} tell application "Finder" activate set myFolder to folder (folderPath as POSIX file) set myFile to first item of myFolder -- set myFile to quoted form of (item 1 of argv) select myFile tell application "System Events" to keystroke "y" using command down end tell end run **Question** 1. In part3 I want to avoid hard coding "/Users/poudel/Dropbox" to "~/Dropbox" so that I can use the workflow in the office computer and my own laptop both. 2. The workflow is not working currently, I am struggling to select the file by its name. Help with workflow is appreciated.
  22. I believe it would be an astonishing feature if there is an option to press "shift" key at snippet so that it stays in floating window so that we can see the codes/notes/any snippet and work altogether. Ideas of implementation: - Using QuickView - Using Helium app which supports floating browser Bonus: It would be even nicer if the codes are syntax highlighted (reading shebang of snippet) Hope we can see this feature in some of the upcoming versions of Alfred.
  • Create New...