Last active
June 11, 2018 08:27
-
-
Save ethaizone/c256c1e9498f4771e81cac753fd0944a to your computer and use it in GitHub Desktop.
[Windows] Make any GUI program and run from CLI. This example is PHPStorm.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
basedir=`dirname "$0"` | |
# This is like symlink for bash cmd such as mintty, GIT bash, Cygwin | |
# I pass parameters to it too. | |
"$basedir/pstorm.cmd" "$@" | |
# Note - I tried create symlink but it not work at bash environment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
:: Automatic is best | |
:: I tested on Windows 10 only. | |
for /f "delims=" %%A in ('dir "C:\Program Files\JetBrains" /s /b ^| findstr /e phpstorm64.exe') do ( | |
start /b "" "%%A" %* | |
) |
Author
ethaizone
commented
Jul 22, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment