This would give all permissions (Read, Write, Execute) to you
sudo chmod 777 -R /path to folder
The permissions (in this case 777) are as follow:
- 7 - Full (Read, Write & Execute)
import os | |
import subprocess | |
root_directory = "/path/to/Projects" | |
def check_repositories(directory): | |
for root, dirs, files in os.walk(directory): | |
if ".git" in dirs: | |
repo_path = os.path.join(root, ".git") | |
repo_dir = os.path.dirname(repo_path) |
git remote prune origin | |
git branch -vv | grep ': gone]'| grep -v "\*" | awk '{ print $1; }' | xargs -r git branch -D |
git rm -r --cached . | |
git add . | |
git commit -m "gitignore updated" |
git checkout master | |
git reset --hard preprod | |
git merge -s ours master | |
git push |
This would give all permissions (Read, Write, Execute) to you
sudo chmod 777 -R /path to folder
The permissions (in this case 777) are as follow:
sudo apt-get update
sudo apt-get install \
apt-transport-https \
ca-certificates \
curl \
software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
chmod +x /<path>/yourscript.sh
/<path>/yourscript.sh
See Details How do I run .sh files?
sudo apt-get -f install
sudo dpkg -i <package-name>.deb
sudo apt install curl
curl -sL https://deb.nodesource.com/setup_8.x | sudo bash -
sudo apt install nodejs
node --version
npm version