File: rbenv-echo

package info (click to toggle)
rbenv 1.3.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 400 kB
  • sloc: sh: 1,259; ruby: 40; makefile: 15
file content (9 lines) | stat: -rwxr-xr-x 157 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
#!/usr/bin/env bash
# Usage: rbenv echo [-F<char>] VAR

if [[ $1 == -F* ]]; then
  sep="${1:2}"
  echo "${!2}" | tr "${sep:-:}" $'\n'
else
  echo "${!1}"
fi