Original post : https://unix.stackexchange.com/a/310699
nmcli con add type wifi ifname wlx7cdd9046ee19 con-name AiRpaperHostspot autoconnect yes ssid AiRpaperHostspot
#Connection 'AiRpaperHostspot' (81bd8ff0-1473-4bda-b00d-5759cd1c3a27) successfully added.
nmcli con modify AiRpaperHostspot 802-11-wireless.mode ap 802-11-wireless.band bg ipv4.method shared
nmcli con modify AiRpaperHostspot wifi-sec.key-mgmt none
#nmcli con modify AiRpaperHostspot wifi-sec.key-mgmt wpa-psk
#https://developer.gnome.org/NetworkManager/stable/settings-802-11-wireless-security.html
#nmcli con modify AiRpaperHostspot wifi-sec.psk "veryveryhardpassword1234"
nmcli con up AiRpaperHostspot
If after reboot nmcli con up AiRpaperHostspot
doesn't work
Use this command instead to start Hotspot
UUID=$(grep uuid /etc/NetworkManager/system-connections/AiRpaperHostspot | cut -d= -f2)
nmcli con up uuid $UUID