mirror of
https://github.com/YunoHost-Apps/hotspot_ynh.git
synced 2024-09-03 19:25:53 +02:00
Clean prerequisites and fix css outline for tabs
This commit is contained in:
parent
4ca40efb43
commit
6fd4b34055
6 changed files with 52 additions and 47 deletions
|
@ -51,8 +51,8 @@
|
|||
{
|
||||
"name": "firmware_nonfree",
|
||||
"ask": {
|
||||
"en": "Install non-free firmwares for the wifi dongle (yes/no)",
|
||||
"fr": "Installer des firmwares non-libres pour la clé USB wifi (yes/no)"
|
||||
"en": "Install non-free firmwares - in addition to the free ones - for the wifi dongle (yes/no)",
|
||||
"fr": "Installer des firmwares non-libres (en plus des libres) pour la clé USB wifi (yes/no)"
|
||||
},
|
||||
"example": "yes",
|
||||
"default": "yes"
|
||||
|
|
|
@ -29,21 +29,8 @@ firmware_nonfree=${5}
|
|||
|
||||
if ! $upgrade; then
|
||||
|
||||
# Check YunoHost version
|
||||
ynh_version=$(sudo dpkg -l yunohost | grep ii | awk '{ print $3 }' | sed 's/\.//g')
|
||||
|
||||
if [ "${ynh_version}" -lt 220 ]; then
|
||||
echo "ERROR: You need a YunoHost version equals or greater than 2.2.0" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
sudo systemctl is-active dnsmasq &> /dev/null
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "ERROR: You need to enable dnsmasq instead of bind9 (apt-get remove bind9 && systemctl start dnsmasq)" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
source ./prerequisites
|
||||
|
||||
# Check arguments
|
||||
if [ -z "${wifi_ssid}" -o -z "${wifi_passphrase}" ]; then
|
||||
echo "ERROR: Your Wifi Hotspot needs a name and a password" >&2
|
||||
|
|
16
scripts/prerequisites
Normal file
16
scripts/prerequisites
Normal file
|
@ -0,0 +1,16 @@
|
|||
# Source me
|
||||
|
||||
# Check YunoHost version (dnsmasq)
|
||||
ynh_version=$(sudo dpkg -l yunohost | grep ii | awk '{ print $3 }' | sed 's/\.//g')
|
||||
|
||||
if [ "${ynh_version}" -lt 220 ]; then
|
||||
echo "ERROR: You need a YunoHost version equals or greater than 2.2.0" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
sudo systemctl is-active dnsmasq &> /dev/null
|
||||
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "ERROR: You need to enable dnsmasq instead of bind9 (apt-get remove bind9 && systemctl start dnsmasq)" >&2
|
||||
exit 1
|
||||
fi
|
|
@ -12,6 +12,8 @@ path=$(ynh_setting hotspot path)
|
|||
wifi_ssid=$(ynh_setting hotspot wifi_ssid)
|
||||
wifi_passphrase=$(ynh_setting hotspot wifi_passphrase)
|
||||
|
||||
source ./prerequisites
|
||||
|
||||
if dpkg -l firmware-linux-nonfree &> /dev/null; then
|
||||
firmware_nonfree=yes
|
||||
else
|
||||
|
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2015-09-15 21:41+0200\n"
|
||||
"POT-Creation-Date: 2015-09-29 16:56+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
@ -17,40 +17,40 @@ msgstr ""
|
|||
"Content-Type: text/plain; charset=CHARSET\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: sources/controller.php:199
|
||||
msgid "All Wifi names must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:205
|
||||
msgid "All IPv4 NAT prefixes must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:211
|
||||
msgid "All IPv6 delegated prefixes must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:217
|
||||
msgid "Your Wifi Hotspot needs a name and a password"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:221
|
||||
msgid "Your password must from 8 to 63 characters (WPA2 passphrase)"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:225
|
||||
msgid ""
|
||||
"Only <LINK:ASCII>printable ASCII characters</LINK:ASCII> are permitted in "
|
||||
"your password"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:234
|
||||
#: sources/controller.php:188
|
||||
msgid "You have to choose a wifi antenna interface"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:237
|
||||
#: sources/controller.php:191
|
||||
msgid "The wifi antenna interface seems not exist on the system"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:207
|
||||
msgid "All Wifi names must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:213
|
||||
msgid "All IPv4 NAT prefixes must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:219
|
||||
msgid "All IPv6 delegated prefixes must be unique"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:225
|
||||
msgid "Your Wifi Hotspot needs a name and a password"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:229
|
||||
msgid "Your password must from 8 to 63 characters (WPA2 passphrase)"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:233
|
||||
msgid ""
|
||||
"Only <LINK:ASCII>printable ASCII characters</LINK:ASCII> are permitted in "
|
||||
"your password"
|
||||
msgstr ""
|
||||
|
||||
#: sources/controller.php:244
|
||||
msgid "The IPv6 Delegated Prefix format looks bad"
|
||||
msgstr ""
|
||||
|
|
|
@ -150,7 +150,7 @@ div.tabs {
|
|||
padding: 14px 14px 0 10px;
|
||||
}
|
||||
|
||||
div.tabs a {
|
||||
ul.nav a {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue