_voxl-vins-autoconf(){

	local OPTS=('--apply --conf --yaml-dir --profile --rs-convention --enable-zcal --disable-zcal --log --help')

	COMPREPLY=()
	local cur="${COMP_WORDS[COMP_CWORD]}"
	local prev="${COMP_WORDS[COMP_CWORD-1]}"
	case "$prev" in
		--profile)
			local PROFILES=$(ls /usr/share/modalai/voxl-open-vins/VoxlConfig 2>/dev/null)
			COMPREPLY=( $(compgen -W "${PROFILES}" -- ${cur}) )
			return 0
			;;
		--rs-convention)
			COMPREPLY=( $(compgen -W 'top center bottom' -- ${cur}) )
			return 0
			;;
		--log|--conf|--yaml-dir)
			COMPREPLY=( $(compgen -o dirnames -- ${cur}) )
			return 0
			;;
	esac
	COMPREPLY=( $(compgen -W '${OPTS}' -- ${cur}) )
}

complete -F _voxl-vins-autoconf voxl-vins-autoconf
