#!/bin/bash
# Get full path to npx
FULL_PATH_TO_NPX=$(which npx)
# Extract ASDF shims directory (remove '/npx' from the path)
PATH_TO_ASDF_SHIMS_DIR=$(dirname "$FULL_PATH_TO_NPX")
# Get full path to asdf
This file contains hidden or 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
# Install ASDF version manager and plugins | |
if ! command -v asdf &> /dev/null; then | |
brew install asdf | |
echo -e "\n. $(brew --prefix asdf)/libexec/asdf.sh" >> ${ZDOTDIR:-~}/.zshrc | |
fi | |
asdf plugin add nodejs https://github.com/asdf-vm/asdf-nodejs.git || true | |
asdf plugin add python || true | |
asdf plugin add rust || true |
# create a new project
poetry new {project_name}
# add a package
poetry add {package_name}
# install dependencies
poetry install
This file contains hidden or 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
import json | |
import subprocess | |
# This script requires gh command if you don't have it, you need to install. | |
# Run the gh command and get the output | |
user_id = input('Enter your github id: ') | |
repo_owner = input('Enter repo owner: ') | |
repo = input('Enter repo name: ') | |
limit = input('Enter limit num: ') |
#!/bin/bash
folder_path="./protocols"
output_file="./simulate_output.txt"
for file_path in $folder_path/*.py; do
echo "run $file_path" >> "$output_file"
output=$(opentrons_simulate "$file_path")
echo "$output" >> "$output_file"
when running wsl, wsl creates resolv.conf and add useless nameserver. the following is to prevent that.
sudo rm /etc/resolv.conf
sudo zsh -c 'echo "nameserver 8.8.8.8" > /etc/resolv.conf'
sudo zsh -c 'echo "[network]" > /etc/wsl.conf'
sudo zsh -c 'echo "generateResolvConf = false" >> /etc/wsl.conf'
{
"id":"6980139750690950405",
"desc":"#umortiktok #umor2021 #viraltiktok #sonrriesoloeshumor🤣",
"createTime":1625190436,
"video":{
"id":"6980139750690950405",
"height":1024,
"width":576,
"duration":8,
#!/bin/bash
# create tsconfig.json
echo "Create tsconfig.json"
touch tsconfig.json
# install packages for typescript
echo "install packages"
YARNCOMMAND='yarn add --dev typescript @types/react @types/node'
if $YARNCOMMAND ; then
NewerOlder