Warning: Work in progress! Leave feedback on Zulip or Github if you'd like this doc to be updated.

OSH Assignment

This chapter in the Oils Reference describes OSH assignment.

Table of Contents
Operators
sh-assign
sh-append
Compound Data
sh-array
sh-assoc
Builtins
local
export
unset
shift
declare
typeset

Operators

sh-assign

sh-append

Compound Data

sh-array

Array literals in shell accept any sequence of words, just like a command does:

ls $mystr "$@" *.py

# Put it in an array
a=(ls $mystr "$@" *.py)

In YSH, use oil-array.

sh-assoc

In YSH, use oil-dict.

Builtins

local

export

unset

shift

declare

typeset

Alias for declare.


Generated on Sun, 04 Feb 2024 00:32:22 -0500