docs: add nested object to examples

Signed-off-by: jolheiser <john.olheiser@gmail.com>
main
jolheiser 2024-06-09 20:47:30 -05:00
parent c3e43f01e0
commit 159c6ae362
Signed by: jolheiser
GPG Key ID: B853ADA5DA7BBF7A
7 changed files with 40 additions and 4 deletions

View File

@ -4,4 +4,11 @@ in { username = name
, home = "/home/${name}" , home = "/home/${name}"
, admins = [ name, "admin" ] , admins = [ name, "admin" ]
, email = "${name}@example.com" , email = "${name}@example.com"
, address =
{ street = "123"
, country = "USA"
, state = "MT"
, zip = "12345"
, phone = "123-456-7890"
}
} }

View File

@ -1,4 +1,11 @@
{ {
"address": {
"country": "USA",
"phone": "123-456-7890",
"state": "MT",
"street": "123",
"zip": "12345"
},
"admins": [ "admins": [
"jolheiser", "jolheiser",
"admin" "admin"

View File

@ -1,10 +1,18 @@
{ {
// User's address
"address": {
"country": "USA",
"phone": "123-456-7890",
"state": "MT",
"street": "123",
"zip": "12345"
},
// Admins for foobar
"admins": [ "admins": [
"jolheiser", "jolheiser",
"admin" "admin"
], ],
"email": "jolheiser@example.com", "email": "jolheiser@example.com",
"home": "/home/jolheiser", "home": "/home/jolheiser",
// The user! "username": "jolheiser" // User's name
"username": "jolheiser",
} }

View File

@ -1,4 +1,5 @@
home "/home/jolheiser"
admins "jolheiser" "admin" admins "jolheiser" "admin"
email "jolheiser@example.com" email "jolheiser@example.com"
address state="MT" zip="12345" phone="123-456-7890" street="123" country="USA"
username "jolheiser" username "jolheiser"
home "/home/jolheiser"

View File

@ -1 +1 @@
{ admins = [ "jolheiser" "admin" ]; email = "jolheiser@example.com"; home = "/home/jolheiser"; username = "jolheiser"; } { address = { country = "USA"; phone = "123-456-7890"; state = "MT"; street = "123"; zip = "12345"; }; admins = [ "jolheiser" "admin" ]; email = "jolheiser@example.com"; home = "/home/jolheiser"; username = "jolheiser"; }

View File

@ -2,3 +2,10 @@ admins = ['jolheiser', 'admin']
email = 'jolheiser@example.com' email = 'jolheiser@example.com'
home = '/home/jolheiser' home = '/home/jolheiser'
username = 'jolheiser' username = 'jolheiser'
[address]
country = 'USA'
phone = '123-456-7890'
state = 'MT'
street = '123'
zip = '12345'

View File

@ -1,3 +1,9 @@
address:
country: USA
phone: 123-456-7890
state: MT
street: "123"
zip: "12345"
admins: admins:
- jolheiser - jolheiser
- admin - admin