This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo "GROUP=alpha" > /etc/coreos/update.conf # This is not good idea because of unstable updates, so risky for production | |
sudo systemctl restart update-engine | |
update_engine_client -check_for_update | |
# for checking os version after restarting | |
cat /etc/os-release | |
# source from https://coreos.com/os/docs/latest/switching-channels.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Get all files with uppercase MP4 and MOV | |
files='*.MP4 *.MOV'; | |
# Go through files | |
for f in $files; | |
do | |
# Create a regexp for find compressed file | |
regexp=$(echo $f | sed -e "s/\(.*\)\(\.\)\(...\)/\1\*.\L\3/"| tr -d '\n'); | |
# Find compressed file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Consume update args object for document and can handle one level nesting. | |
* Returns object for leverage by $set in Mongoose update function. | |
* | |
* @param args | |
* @returns {{}} | |
*/ | |
const objectToDotNotation = (args) => { | |
const setObject = {}; | |
Object.keys(args).forEach((key) => { |