summaryrefslogtreecommitdiff
path: root/lib/functions.zsh
AgeCommit message (Collapse)Author
2016-12-30 'lib/functions.zsh: Solve typos'Patrick José Pereira
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2016-08-09Replace /bin/sh with sh for portability (#5291)Fredrik Fornwall
This makes things work even on system lacking /bin/sh, such as on non-rooted Android systems.
2015-11-30Use shwordsplit in open_command()Marc Cornellà
2015-11-30Add empty string parameter to start commandMarc Cornellà
Otherwise `start` will confuse the first parameter as the title of a new command prompt if the parameter contains whitespace. That is because the command to be run will be: start "abc def" which opens a new command prompt window with the title "abc def". With the added empty string we force the start command to interpret the passed parameter as the file / command: start "" "abc def" which will be interpreted like `""` is the title and the rest is the file or command to start. ------- **NOTE:** this wouldn't be necessary if the start script in msys was defined differently; that is, if it had the empty string already incorporated in the script (/usr/bin/start), like so: ```diff -cmd //c start "${@//&/^&}" +cmd //c start "" "${@//&/^&}" ``` Notice however that this would make it impossible to use start setting a different title, so it's probably best to leave it as is. More info: http://sourceforge.net/p/msys2/tickets/14/ ------- The change `${(z)open_cmd}` is necessary to force zsh to split the variable by the spaces and interpret it as separate words. More info: http://zsh.sourceforge.net/FAQ/zshfaq03.html#l17
2015-11-30make this work in the git-for-windows SDKMark Ingalls
Added an option for the msys value of $OSTYPE
2015-11-29Fix open_command nohup callMarc Cornellà
There a syntax error if $cmd_var contains more than one word, so we drop the current way to prepend nohup and use a simpler if-else form.
2015-11-27termsupport: protect subshell with quotesAndrew Janke
2015-11-27Drop the use of nohup on OSX for tmux compatibilityMarc Cornellà
Apparently `nohup` is not needed in OSX, and using it has the side that it may break under tmux with the error nohup: can't detach from console: No such file or directory For now, this commit only drops the use of `nohup` in OSX. But it *may* not be necessary under other similar platforms.
2015-08-17Merge branch 'master' into fold-terminalapp-plugin-into-termsupportAndrew Janke
2015-08-17Add a deprecation comment.Andrew Janke
2015-08-09Move urlencode/urldecode functions to core libAndrew Janke
2015-08-05Implement cross-platform open function open_command()Marc Cornellà
For now this supports: - Mac OS X - Linux (presumably works on all versions) - Cygwin (Windows)
2014-08-20Replace /usr/bin/env with envFredrik Fornwall
Some environments (such as Android) does not have /usr/bin.
2014-02-06`fc -l 1` instead of `history` in zsh_stats #2501Huang, Tao
$HIST_STAMP breaks zsh_stats. see #2501
2013-12-02Merge pull request #1134 from koraa/pull_req_helpersRobby Russell
Helpers for default variables and alias value access
2012-11-14Improved statistics functions, effect:CHH
1 1124 24.6006% c 2 985 21.5583% git 3 343 7.50711% rails 4 328 7.17881% cd 5 314 6.8724% rspec 6 257 5.62486% la 7 197 4.31167% rake 8 154 3.37054% s 9 109 2.38564% .. 10 95 2.07923% rvm 11 68 1.48829% guard 12 36 0.787919% bundle 13 29 0.634712% ssh 14 28 0.612826% pry 15 27 0.590939% open 16 26 0.569052% middleman 17 26 0.569052% gem 18 24 0.525279% rm 19 24 0.525279% heroku 20 23 0.503392% nvm
2012-05-29Add helper to easily define default values for variables and env variables.mapc
2012-05-29Add helper to get the value of an alias onlymapc
2011-12-25Fix upgrade and uninstall functions to pick up $ZSH valueIndrajit Raychaudhuri
2011-06-01Added extract plugin.Sorin Ionescu
2011-05-26Merge pull request #196 from asymmetric/masterRobby Russell
Add missing flag to unrar
2011-01-30Refactor window and tab title in ttyRenaud (Nel) Morvan
Term window title and tab title are now skinable Tab title can be different from window title (when supported by term) Default theme is optimized of usuability (no %u@%m: $~ in a 10 char tab) Cleanup code duplication and add comment for supported terms On osX it works great on iterm, and is decent once you tweak Terminal pref Tested under GNU screen, iTerm and Apple Terminal, need to be tested on linux TODO implement Konsole support (via dbus)
2011-01-24add missing unrar flagLorenzo Manacorda
2011-01-10Added an option to remove file afterwards.Robin Ramael
2010-12-25Support for more archive formats.SuprDewd
2010-12-24Added a function to extract various archives.SuprDewd
Also an alias for the function.
2010-10-09merging in changes from robby's repoSven Lito
2010-10-08functions: fix title() to not match any $TERMBrandon Philips
On my linux virtual terminals, where TERM="linux", I was getting annoying output that was messing up my prompt. It turns out the title function was always matching on the elif statement for xterm/rxvt no matter what and the linux vt doesn't know what to do with the title special control sequence and thus was printing out garbage. Through experimentation I figured out that the || inside of the [[ ]] did not work: export TERM=linux $ if [[ $TERM =~ "^xterm" || $TERM == "rxvt" ]]; then echo $TERM; fi linux $ if [[ $TERM =~ "^xterm" ]] || [[ $TERM == "rxvt" ]]; then echo $TERM; fi Signed-off-by: Brandon Philips <brandon@ifup.org> openSUSE running zsh 4.3.10
2010-09-30Match xterm-color, the default OS X terminalTrevor Creech
2010-06-03Moving some rails and osx-specific functions to their corresponding plugin filesRobby Russell
2010-06-03Initial implementation of a new plugin system, so that people can managed ↵Robby Russell
which aliases/functions they want.
2009-12-27adding quotes to tab()Dale Campbell
2009-12-16Adding a function that will open up a ticket in Lighthouse based on the ↵Robby Russell
number and there being a URL in a hidden file.
2009-09-23merge upstreamJames Cox
2009-09-23Moving all zsh config options into a lib/ subdirectory to make way for some ↵Robby Russell
upcoming changes to directory structure and configuration options