File: shift

package info (click to toggle)
zsh 5.9-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 23,856 kB
  • sloc: ansic: 108,138; sh: 6,976; makefile: 722; perl: 687; awk: 291; sed: 16
file content (8 lines) | stat: -rw-r--r-- 420 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
shift [ -p ] [ n ] [ name ... ]
       The  positional  parameters  ${n+1}  ...  are renamed to $1 ...,
       where n is an arithmetic expression that defaults to 1.  If  any
       names are given then the arrays with these names are shifted in-
       stead of the positional parameters.

       If the option -p is given arguments are instead removed (popped)
       from the end rather than the start of the array.