[lang-ref] ( get_dirname ) ( bash )

@test "get dirname" {
	# dirname
	[ $(dirname '/path/to/file1.txt') = '/path/to' ]
}
@test "get dirname alternative" {
	# ${fullpath%/*}
	fullpath='/path/to/file1.txt'
	r=${fullpath%/*}
	[ "$r" = '/path/to' ]
}