Introduce Ansible:
- Defined
ansible-playbook
task in.vscode/tasks.json
which is used to run any Ansible playbook in this repo. - The
inventory
folder used by the Ansible playbook tasks in.vscode/tasks.json
is located in Ansible default configuration(/etc/ansible/ansible.cfg
). It is used to define hosts, such as:Then could run theubuntu ansible_host=localhost
ubuntu.yml
playbook to localhost, no need to change the hosts inubuntu.yml
.
In browser
folder, contains some useful Chrome extensions, viewed in HTML pages:
Goto ./browser
Some scripts need choco
, the package manager for Windows.
From official website, this is the command to install choco
(copied on 2020/06/06), need administrative powershell:
Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
VS Code task choco install
leveraged elevation script from cmd - How do you run a command as an administrator from the Windows command line? - Stack Overflow
Scoop installs programs to your home directory by default. So you don’t need admin permissions to install programs, and you won’t see UAC popups every time you need to add or remove a program.
Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh')
https://github.com/microsoft/winget-cli
How to Clear Apt Cache on Ubuntu and Free Crucial Disk Space
sudo apt clean
Install Snapd: https://snapcraft.io/docs/installing-snapd
Snap does not support WSL.
https://docs.brew.sh/Homebrew-on-Linux
The Homebrew package manager may be used on Linux and Windows Subsystem for Linux (WSL). Homebrew was formerly referred to as Linuxbrew when running on Linux or WSL. It can be installed in your home directory, in which case it does not use sudo.
Install: https://sdkman.io/install
SDKMAN is written in bash, it requires a bash environment to be present.
SDKMAN can not be installed natively on Windows and requires WLS, Cygwin or MSYS+MinGW.
curl -s "https://get.sdkman.io" | bash
source "$HOME/.sdkman/bin/sdkman-init.sh"
Windows cmd scripts.
For some scripts, should define MY_OSS environment variable first, towards a folder contains related files
Also, this cmd path should be added to PATH
code --list-extensions
code --install-extension ms-vscode.cpptools
code --uninstall-extension ms-vscode.csharp
Node.js
https://docs.npmjs.com/downloading-and-installing-node-js-and-npm https://www.npmjs.com/
This problem is caused by Bash caching the path of the npm command, and can be solved by hash -d npm
.
From: https://www.jhipster.tech/configuring-a-corporate-proxy/
npm config set proxy http://username:password@host:port
npm config set https-proxy http://username:password@host:port
Or in ~/.npmrc
proxy=http://username:password@host:port
https-proxy=http://username:password@host:port
https_proxy=http://username:password@host:port
pip Installation
Official: https://www.benf.org/other/cfr/
Code: https://github.com/leibnitz27/cfr
Official: http://p-nand-q.com/download/gtools/index.html
Code: https://code.google.com/archive/p/pserv4/ or https://github.com/gersonkurz/pserv4
Official: https://downloads.mysql.com/archives/workbench/
Code: https://github.com/mysql/mysql-workbench/tree/6.3
Tried install using choco
, but got
Attempt to get headers for http://cdn.mysql.com/Downloads/MySQLGUITools/mysql-workbench-community-6.3.8-winx64.msi failed.