Skip to content

Instantly share code, notes, and snippets.

View y-marui's full-sized avatar

Yukihiro y-marui

View GitHub Profile
@y-marui
y-marui / pyenv-win with Anaconda.md
Last active November 11, 2020 02:18
pyenv-win with Anaconda

pyenv-win with Anaconda

Install Anaconda

Find version in Anaconda installer archive and download ${vname}-Windows-${architecture}.exe. Open PowerShell at Download and install with command.

start ${vname}-Windows-${architecture}.exe "/InstallationType=JustMe /AddToPath=0 /RegisterPython=0 /S /D=$env:PYENV\versions\${vname}"

Modify Path

Anaconda has different directory structure from normal python.

@y-marui
y-marui / add-numpy.log
Last active January 24, 2023 03:54
poetry via ssh
> poetry add numpy -vvv
Loading configuration file C:\Users\username\AppData\Roaming\pypoetry\config.toml
Creating virtualenv test in C:\Users\username\src\github.com\y-marui\test\.venv
Using virtualenv: C:\Users\username\src\github.com\y-marui\test\.venv
Stack trace:
4 ~\.pyenv\pyenv-win\versions\3.11.1\Lib\site-packages\win32ctypes\pywin32\pywintypes.py:35 in pywin32error
33│ def pywin32error():
34│ try:
@y-marui
y-marui / gist:85e2c40d4f5b71af98849b84524d8071
Created November 15, 2023 01:53
Confirm dialog in macOS terminal
FLAG=$(osascript -e 'display dialog "アップデートを開始します。"'); if [[ $FLAG == "button returned:OK" ]]; then echo "アップデート"; else echo "キャ ンセル"; fi
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.