Posts

Showing posts from September 8, 2018

Renaming USB-LAN dongle iface for gui logon with gdm on Xorg

Image
Clash Royale CLAN TAG #URR8PPP up vote 3 down vote favorite [4.13.9-1-ARCH with gdm on Xorg] I saw quite a few posts (e.g. here) related to starting a service at boot or recognizing a usb drive. But here I want to rename the default Ethernet (wired) iface of my USB LAN dongle to net0 at boot time, or at least BEFORE systemd service netctl-ifplugd@net0.service kicks in. I first tried the Archlinux forum suggestion: $ sudo cat /etc/udev/rules.d/10-network.rules SUBSYSTEM=="net",ACTION=="add", ATTRaddress=="_mac_address_here_", NAME="net0" EDIT: The udev rule is executed when I log on to console. No prbm there. If I wait say 1 minute before I log in via the gdm login menu, the iface is also correctly renamed However if I log on via my gdm logon menu immediately after it appears on screen (that takes me about 3 to 5 seconds), then the interface is not renamed by the udev rule. When that happens, if I unplug and re-plug the USB LAN don...

Bash script failing with unknown option due to space in argument [duplicate]

Image
Clash Royale CLAN TAG #URR8PPP up vote 0 down vote favorite This question already has an answer here: Why does my shell script choke on whitespace or other special characters? 4 answers I am trying to run aws create lambda function. It goes as follows - eval $(aws lambda create-function --function-name $FUNCTION_NAME --runtime $RUNTIME --role $ROLE --handler $HANDLER --region $REGION --zip-file $ZIP_FILE --profile $PROFILE --environment $env_variables) All the variables come from command line. It is failing for env_variables. This gets constructed as - env_variables="Variables=INPUT=$DAYS" where DAYS is actually "20 days" How can I avoid this space and pass my command successfully. shell-script shell quoting share | improve this question edited Nov 4 '17 at 18:50 Gilles 507k 120 1003 1532 asked Nov 4 '17 at 13:45 Aniket Thakur 243 1 11 marked as duplicate by Gilles  shell Users with the  shell ...