Jump to content

Search the Community

Showing results for tags 'iterm2'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Alfred 3
  • Make the Most of Alfred
    • Discussion & Help
    • Bug Reports
    • Alfred Feature Suggestions
    • Themes
  • Alfred Workflows
    • Share your Workflows
    • Workflow Help & Questions
  • Alfred v2 Themes
  • Alfred Remote for iOS
    • Alfred Remote Discussion & Help
    • Remote Connection Troubleshooting

Categories

  • Articles
    • Forum Integration
    • Frontpage
  • Pages
  • Miscellaneous
    • Databases
    • Templates
    • Media

Categories

  • New Features
  • Other

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Twitter


Website URL


Jabber


Location


Interests

Found 8 results

  1. Hey everybody! I am working on this workflow where I have a file filter with the most important text files (for me, at least) to open with vim in iTerm. Currently I have it configured so that I can choose to just run vim and get a new document or I can choose to run "v $SOMEFILE" in Alfred to make it open that way. It's super cool, I've used https://github.com/stuartcryan/custom-iterm-applescripts-for-alfred/ and Macvimtoolbox as inspiration for this. There is one bug, however. When the active iTerm window is not just showing a prompt but engaged, then the script doesn't open a new windows but just pastes the "nvim /path/to/file" into the window. I'd like to configure the Apple-script to just open a new window in that case. How do I do that? The code I'm using is here, btw: on alfred_script(q) my runIniTerm( "nvim " & q & "" ) end alfred_script -- This is v0.5 of the custom script for AlfredApp for iTerm 2.9+ -- Please see https://github.com/stuartcryan/custom-iterm-applescripts-for-alfred/ -- for the latest changes. on is_running(app_name) tell application "System Events" to (name of processes) contains app_name end is_running -- Please note, if you store the iTerm binary in any other location than the Applications Folder -- please ensure you update the two locations below (in the format of : rather than / for folder dividers) -- this gets around issues with AppleScript not handling things well if you have two iTerm binaries on your system... which can happen on runIniTerm(q) if is_running("iTerm2") or is_running("iTerm") then run script " on run {q} tell application \":Applications:iTerm.app\" activate try select first window set onlywindow to true on error create window with default profile select first window set onlywindow to true end try tell the first window if onlywindow is false then create tab with default profile end if tell current session to write text q end tell end tell end run " with parameters {q} else run script " on run {q} tell application \":Applications:iTerm.app\" activate try select first window on error create window with default profile select first window end try tell the first window tell current session to write text q end tell end tell end run " with parameters {q} end if end runIniTerm The workflow can be found here: https://transfer.sh/Ul5L3/Open-files-with-Vim.alfredworkflow
  2. A JXA-based workflow for Alfred 3 users to quickly switch between or close iTerm windows, tabs and panes based on title and tty, or trigger your preferred ssh workflow when no open session is found (supports both isometry/alfred-ssh and deanishe/alfred-ssh). GitHub: https://github.com/isometry/alfred-tty Latest Release: https://github.com/isometry/alfred-tty/releases/latest Usage Trigger the workflow with the keyword tty or via hotkey followed by some characters from the title of an open window, tab or pane; press Enter to activate the selected window/tab/pane, Alt-Enter to close it, or Cmd-Enter to trigger your ssh workflow. For example, enter tty as3 to switch to a tab with the title user@azure-server-03. If no active terminal matches, or you use the Cmd-modifier, trigger your preferred ssh workflow, e.g. ⇄ ssh as3. By default, the ssh workflow is assumed to be net.isometry.alfred.ssh (i.e. isometry/alfred.ssh, version 2.3+). Override by setting the ssh_workflow and ssh_trigger variables; for deanish/alfred-ssh, set the ssh_workflow variable to net.deanishe.alfred-ssh. In order to make working with more than one window/tab/pane with the same title easier, the tty is displayed beneath the result, and can be provided as a second argument to the trigger. For example, enter tty lo 3 to select the the session with title localhost running on /dev/ttys003. To select by tty alone, use two spaces between the trigger and the tty number. For example, tty 4 will select /dev/ttys004. Optionally associate a hotkey trigger to further accelerate operation, e.g. Ctrl+Cmd+T, or change the trigger word via the keyword variable. Combine with an iTerm2 profile configured as ssh protocol handler (e.g. Name:=$$USER$$@$$HOST$$, Command:=$$ and Schemes handled:=ssh) and an alfred-ssh workflow to make opening and jumping between remote sessions across many windows, tabs and panes easy.
  3. * What you were doing when the issue happened Nothing in particular. * Whether you were able to replicate it a second time by performing the same action Yes, the issue is reproducible. * Include any screenshots that might help us Here's a video demonstration of a snippet properly expanding in TextEdit but not in iTerm2, which has Secure Keyboard Entry disabled: I've also attached a screenshot of iTerm2 preferences. * Include the Alfred version & build number you are using Alfred 3.3 (801) * Include your OS X version macOS 10.11.6 (15G1212) iTerm2 3.0.13
  4. Alfred workflow to quickly select of one currently opened iTerm sessions Just type “sessions” and it will show currently opened iTerm sessions. Optionally, you can type text to filter by session name. You can download on Github: https://github.com/madvas/alfred-iterm-sessions
  5. Hi Team, I seem to be having a bit of an issue that has cropped up in the last few weeks, I am not sure exactly when it started but the symptoms are this: 1. When I try to execute a terminal command with '.< command >' or a workflow tries to execute a terminal command... if I don't already have iTerm open, nothing happens at all. 2. If I manually open iTerm and have it running in the background... everything runs fine. This seems to occur across all three of my Macs. Versions: iTerm2 2.1.1 OSX: 10.10.4 Alfred: 2.7.1 (387) I have had a look and turned on all info for one of the flows and it does not error out at all, this seems to execute successfully: [iNFO: alfred.workflow.input.keyword] Processing output 'alfred.workflow.action.terminalcommand' with arg '' But strangely iTerm2 is never opened. It seems the iTerm2 program is now just called iTerm in my Applications folder, not sure if this has affected things at all (or if it always was). I have also checked the system console and no errors seem to be outputted to any system logs during the time I was testing. Look forward to hearing from you. Cheers, Stuart Update: All righty and now I have updated the scripts... made them more awesome and even added one for iTerm 2.9 https://github.com/stuartcryan/custom-iterm-applescripts-for-alfred/tree/master Not sure the best way to publish this but if anyone has any issues let me know and I will try to tweak the scripts further. Cheers, Stuart
  6. Hello, Here is a workflow that let you choose between preconfigured iTerm2 windows/panes configurations. This is useful when you have to work with different terminal windows. And possibly launch remote ssh session in each one to process some "tail -f" kind of real time log analysis. This workflow is an Apple Script script that embed your windows configuration. So you have to configure/set/change the configs you will call as parameter from the keywords. Dependencies: iTerm2. Configuration: At top of AppleScript. Download: Alfred2-iTerm2 on GitHub. Olivier.
  7. This is a pretty specific and convoluted workflow, but one that I use quite a few times daily. Who's it for: It is useful to developers using the Corona SDK toolkit to create mobile apps. What it does: For a given string parameter, it searches a specified directory for subdirectories of that name which contain a main.lua file. Once it's found that it starts a new iTerm2 session and launches the Corona Terminal app with that main.lua file as an argument. Gotchas: Corona Terminal doesn't play nice with directories with spaces in the names. The original was written for Alfred 1. As it just invokes the script, the workflow is trivial, with the exception that you need to cd into the directory with the scripts first. My Run Script workflow element contains: cd script_directory python -u corona_launch.py ~/Programming/ {query} Here's the github for the original: https://github.com/personalnadir/Launch-Corona-with-iTerm2
  8. I like to quickly get to the terminal and quickly hide it. This Alfred workflow allows you to show/hide iTerm with Shift+Cmd+Space. Download
×
×
  • Create New...