Latest
This commit is contained in:
parent
0359793ca2
commit
14b9d2c58b
18 changed files with 306 additions and 32 deletions
|
@ -80,4 +80,5 @@
|
|||
* https://anonaddy.com/
|
||||
* https://claper.co/
|
||||
* https://namelix.com/
|
||||
* https://gchq.github.io/CyberChef
|
||||
* https://gchq.github.io/CyberChef
|
||||
* https://github.com/sourcerer-io/sourcerer-app
|
33
docs/TODO.md
33
docs/TODO.md
|
@ -3,35 +3,25 @@
|
|||
xattr -d com.apple.quarantine rclone
|
||||
|
||||
# TODOs
|
||||
[Title](https://github.com/ViktorBusk/LunarChad)
|
||||
[Title](https://github.com/highlight/highlight)
|
||||
|
||||
This page outlines various projects and tasks that we are currently working on. Creating a GitHub issue for each of these items would be overkill.
|
||||
* [Title](https://www.ipfire.org/)
|
||||
|
||||
* https://github.com/PromtEngineer/localGPT
|
||||
* https://github.com/StanGirard/quivr
|
||||
* [IP Fire](https://www.ipfire.org/) - Consider as alternative to pfSense on Qubes.
|
||||
* `git-credential-manager configure`
|
||||
* [Title](https://github.com/git-ecosystem/git-credential-manager/blob/release/docs/wsl.md)
|
||||
* [Title](https://github.com/KnowledgeCanvas/knowledge)
|
||||
* [`git-credential-manager` for WSL](https://github.com/git-ecosystem/git-credential-manager/blob/release/docs/wsl.md)
|
||||
* Configure Navi to automatically download and use the best cheat repositories
|
||||
* Python
|
||||
* adb must be accessible in PATH: brew install --cask android-platform-tools
|
||||
* https://github.com/Paul-Reed/cloudflare-ufw
|
||||
* Google Drive index on Cloudflare https://github.com/menukaonline/goindex-extended
|
||||
* Use https://github.com/0xERR0R/blocky
|
||||
* https://github.com/butlerx/wetty
|
||||
* Add https://github.com/badaix/snapcast
|
||||
* Go through https://github.com/jaywcjlove/awesome-mac
|
||||
* https://codesandbox.io/ https://github.com/firecracker-microvm/firecracker
|
||||
* (https://www.kolide.com/features/checks/mac-firewall)
|
||||
* (https://github.com/tobiasbueschel/search-gpt)
|
||||
* Create IP set for CloudFlare [Title](https://firewalld.org/documentation/man-pages/firewalld.ipset.html)
|
||||
* https://chainner.app/
|
||||
* https://github.com/kyrolabs/awesome-langchain)
|
||||
( [Title](https://github.com/StanGirard/quivr))
|
||||
* [Title](https://github.com/PromtEngineer/localGPT)
|
||||
* [Title](https://github.com/reworkd/AgentGPT)
|
||||
* deprecate ansible roles in softwareyml
|
||||
* https://github.com/kyrolabs/awesome-langchain
|
||||
* Create seed for Lulu
|
||||
* [Title](https://github.com/essandess/macOS-Fortress)
|
||||
( https://github.com/sourcerer-io/sourcerer-app)
|
||||
* https://github.com/essandess/macOS-Fortress
|
||||
* https://wakatime.com/plugins
|
||||
|
||||
## Upstream
|
||||
|
||||
|
@ -78,6 +68,7 @@ The following links include software that need to be reviewed before including t
|
|||
|
||||
The following items are Docker containers that we may want to include as default containers deployed in our system.
|
||||
|
||||
* https://github.com/highlight/highlight
|
||||
* https://github.com/jitsi/jitsi-videobridge
|
||||
* https://github.com/gitlabhq/gitlabhq
|
||||
* https://github.com/opf/openproject
|
||||
|
@ -114,7 +105,7 @@ The following items are Docker containers that we may want to include as default
|
|||
* https://github.com/umputun/remark42 - Comments
|
||||
* https://github.com/meienberger/runtipi - Home server
|
||||
* https://github.com/bytebase/bytebase
|
||||
* https://github.com/IceWhaleTech/CasaOS - Home page https://github.com/ajnart/homarr https://github.com/phntxx/dashboard https://github.com/notclickable-jordan/starbase-80
|
||||
* https://github.com/IceWhaleTech/CasaOS - Home page https://github.com/ajnart/homarr https://github.com/phntxx/dashboard
|
||||
* https://github.com/usememos/memos - Memo page
|
||||
* https://github.com/outline/outline - Team notes
|
||||
* https://github.com/directus/directus - SQL
|
||||
|
@ -204,7 +195,7 @@ The following items have been reviewed but need to be revisited due to complexit
|
|||
* https://github.com/Kanaries/Rath
|
||||
* cvat.io
|
||||
* https://github.com/illacloud/illa-builder
|
||||
*
|
||||
* https://github.com/KnowledgeCanvas/knowledge
|
||||
* https://github.com/siyuan-note/siyuan
|
||||
* https://github.com/shuttle-hq/shuttle
|
||||
* https://github.com/open-hand/choerodon
|
||||
|
|
|
@ -850,6 +850,8 @@ softwareGroups:
|
|||
Python: &Python
|
||||
- flake8
|
||||
- isort
|
||||
- mambaforge
|
||||
- micromamba
|
||||
- poetry
|
||||
- python
|
||||
- virtualenv
|
||||
|
|
|
@ -222,6 +222,32 @@
|
|||
clone.args = ["--depth", "1"]
|
||||
pull.args = ["--ff-only"]
|
||||
|
||||
### AI / GPT
|
||||
[".local/share/agentgpt"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/reworkd/AgentGPT.git"
|
||||
refreshPeriod = "{{ $refreshPeriod }}"
|
||||
clone.args = ["--depth", "1"]
|
||||
pull.args = ["--ff-only"]
|
||||
[".local/share/localgpt"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/PromtEngineer/localGPT.git"
|
||||
refreshPeriod = "{{ $refreshPeriod }}"
|
||||
clone.args = ["--depth", "1"]
|
||||
pull.args = ["--ff-only"]
|
||||
[".local/share/shortgpt"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/rayventura/shortgpt.git"
|
||||
refreshPeriod = "{{ $refreshPeriod }}"
|
||||
clone.args = ["--depth", "1"]
|
||||
pull.args = ["--ff-only"]
|
||||
[".local/share/quivr"]
|
||||
type = "git-repo"
|
||||
url = "https://github.com/StanGirard/Quivr.git"
|
||||
refreshPeriod = "{{ $refreshPeriod }}"
|
||||
clone.args = ["--depth", "1"]
|
||||
pull.args = ["--ff-only"]
|
||||
|
||||
### Ansible Roles / Playbook
|
||||
[".local/share/gas-station"]
|
||||
type = "git-repo"
|
||||
|
|
7
home/.chezmoitemplates/secrets/REPLICATE_API_KEY
Normal file
7
home/.chezmoitemplates/secrets/REPLICATE_API_KEY
Normal file
|
@ -0,0 +1,7 @@
|
|||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBLc092amhmUmNHeS9aUS85
|
||||
UkptOHJ5YWdUa2Z2bGIxR3pMNnlqem1JcmpBCm9rL3dNR2RXdVNveVR5bDQ1cWti
|
||||
TUFYSGEvekVqOHNWSWxiQWNjQUhwancKLS0tIHVCQWUySFBZNzZ6NDNvNEFHaEN0
|
||||
NjVreUgxNHpocTBMM0JVQVlLdmt3bGsK4kEPtN7EGEdNi3q9Jqm0L5JlENYu3D+a
|
||||
DGXIrItTwF3TR7dUAK8edlJqLg5RRuChIJ0JLxhtLEbXgotfaOP9i0KjEbL8tBGX
|
||||
-----END AGE ENCRYPTED FILE-----
|
7
home/.chezmoitemplates/secrets/SERP_API_KEY
Normal file
7
home/.chezmoitemplates/secrets/SERP_API_KEY
Normal file
|
@ -0,0 +1,7 @@
|
|||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBZamY3dTRnbmZLOUdUME5N
|
||||
MnhkYk0rK0M4VTRTVm9vZ09ERndXa3drM2p3CjJ1VGIrWmpSRlFlWWl2NXJQUkNo
|
||||
M3NObjVlZlYrc1dFVjY5cjJNY2pVMHcKLS0tIDNpb2JwcEtVeUdKdXVMV09maklG
|
||||
UWxoTUk3dEpCWmpiTlFCWkVObXpQaEkKNVqBJ+f+VaxnM7urPMBljIN9V524rVBs
|
||||
iqgxiVb+UR7K82gAzMkIyKpj8KfSOWqR1wtFh2g/LLNr+Ful9/ZwyWURiJ3nkooy
|
||||
-----END AGE ENCRYPTED FILE-----
|
|
@ -124,6 +124,43 @@ if [ "$BASH_SUPPORT" = 'true' ]; then
|
|||
. "$HOME/.fig/shell/bashrc.post.bash"
|
||||
fi
|
||||
|
||||
### Mamba Forge (Faster Conda Drop-In Replacement)
|
||||
# TODO: Add logic for Linux
|
||||
if [ -f /usr/local/Caskroom/mambaforge/base/bin/conda ]; then
|
||||
# >>> conda initialize >>>
|
||||
# !! Contents within this block are managed by 'conda init' !!
|
||||
__conda_setup="$('/usr/local/Caskroom/mambaforge/base/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"
|
||||
if [ $? -eq 0 ]; then
|
||||
eval "$__conda_setup"
|
||||
else
|
||||
if [ -f "/usr/local/Caskroom/mambaforge/base/etc/profile.d/conda.sh" ]; then
|
||||
. "/usr/local/Caskroom/mambaforge/base/etc/profile.d/conda.sh"
|
||||
else
|
||||
export PATH="/usr/local/Caskroom/mambaforge/base/bin:$PATH"
|
||||
fi
|
||||
fi
|
||||
unset __conda_setup
|
||||
# <<< conda initialize <<<
|
||||
fi
|
||||
|
||||
### Micro-Mamba
|
||||
# Generate command: micromamba shell init -s bash -p "${XDG_DATA_HOME:-$HOME/.local/share}/micromamba"
|
||||
# TODO: Ensure Linux support
|
||||
if [ -f /usr/local/bin/micromamba ]; then
|
||||
# >>> mamba initialize >>>
|
||||
# !! Contents within this block are managed by 'mamba init' !!
|
||||
export MAMBA_EXE='/usr/local/bin/micromamba';
|
||||
export MAMBA_ROOT_PREFIX="${XDG_DATA_HOME:-$HOME/.local/share}/micromamba";
|
||||
__mamba_setup="$("$MAMBA_EXE" shell hook --shell bash --root-prefix "$MAMBA_ROOT_PREFIX" 2> /dev/null)"
|
||||
if [ $? -eq 0 ]; then
|
||||
eval "$__mamba_setup"
|
||||
else
|
||||
alias micromamba="$MAMBA_EXE" # Fallback on help from mamba activate
|
||||
fi
|
||||
unset __mamba_setup
|
||||
# <<< mamba initialize <<<
|
||||
fi
|
||||
|
||||
### Navi (Ctrl+G)
|
||||
if command -v navi > /dev/null; then
|
||||
eval "$(navi widget bash)"
|
||||
|
|
|
@ -40,11 +40,13 @@ The following plugins were tested but removed because the `extensions.json` alre
|
|||
"ms-kubernetes-tools.kind-vscode",
|
||||
"ms-toolsai.vscode-ai-remote", // Error encountered: [vscode-ai]: Couldn't find message for key azureml.internal.activate.title.
|
||||
"ms-toolsai.vscode-ai",
|
||||
"ms-vscode.cpptools-extension-pack",
|
||||
"ms-vscode.powershell",
|
||||
"msazurermtools.azurerm-vscode-tools",
|
||||
"nrwl.angular-console",
|
||||
"okteto.kubernetes-context",
|
||||
"okteto.remote-kubernetes",
|
||||
"orta.vscode-jest",
|
||||
"owenfarrell.vscode-vault",
|
||||
"platformio.platformio-ide", // Creates ~/.platformio folder. Does not respect XDG spec.
|
||||
"pwabuilder.pwa-studio",
|
||||
|
|
|
@ -121,11 +121,9 @@
|
|||
"ms-vscode-remote.remote-ssh-edit",
|
||||
"ms-vscode-remote.remote-ssh",
|
||||
"ms-vscode-remote.remote-wsl",
|
||||
"ms-vscode-remote.vscode-remote-extensionpack",
|
||||
"ms-vscode.azure-account",
|
||||
"ms-vscode.azure-repos",
|
||||
"ms-vscode.azurecli",
|
||||
"ms-vscode.cpptools-extension-pack",
|
||||
"ms-vscode.cpptools",
|
||||
"ms-vscode.hexeditor",
|
||||
"ms-vscode.live-server",
|
||||
|
@ -136,7 +134,6 @@
|
|||
"ms-vscode.test-adapter-converter",
|
||||
"ms-vscode.vscode-github-issue-notebooks",
|
||||
"ms-vscode.vscode-js-profile-flame",
|
||||
"ms-vscode.vscode-node-azure-pack",
|
||||
"ms-vscode.vscode-serial-monitor",
|
||||
"ms-vscode.wordcount",
|
||||
"ms-vsliveshare.vsliveshare",
|
||||
|
@ -153,7 +150,6 @@
|
|||
"nhoizey.gremlins",
|
||||
"njpwerner.autodocstring",
|
||||
"oliversturm.fix-json",
|
||||
"orta.vscode-jest",
|
||||
"pdconsec.vscode-print",
|
||||
"philnash.ngrok-for-vscode",
|
||||
"pkief.material-icon-theme",
|
||||
|
|
|
@ -273,6 +273,7 @@
|
|||
"vscode-neovim.neovimExecutablePaths.linux": "/usr/bin/nvim",
|
||||
"vsicons.dontShowNewVersionMessage": true,
|
||||
"vscode-kubernetes.helm-path": "/usr/local/bin/helm",
|
||||
"wakatime.apiKey": "{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "WAKATIME_API_KEY")) }}{{ includeTemplate "secrets/WAKATIME_API_KEY" | decrypt | trim }}{{ else }}{{ env "WAKATIME_API_KEY" }}{{ end }}",
|
||||
"vscord.status.buttons.button1.active.enabled": true,
|
||||
"wallaby.codeLensFeature.runTest": true,
|
||||
"wallaby.compactMessageOutput": true,
|
|
@ -48,6 +48,7 @@ export PATH="$HOME/.local/bin/cask:$PATH"
|
|||
export PATH="$HOME/.local/bin/docker:$PATH"
|
||||
export PATH="$HOME/.local/bin/firejail:$PATH"
|
||||
export PATH="$HOME/.local/bin/flatpak:$PATH"
|
||||
export PATH="$HOME/.local/bin/gpt:$PATH"
|
||||
export PATH="$HOME/.local/bin/mackup:$PATH"
|
||||
export SSH_KEY_PATH="$HOME/.ssh/id_rsa"
|
||||
|
||||
|
|
|
@ -84,11 +84,17 @@ export PEXELS_API_KEY="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplat
|
|||
### PyPi
|
||||
export PYPI_TOKEN="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "PYPI_TOKEN")) }}{{ includeTemplate "secrets/PYPI_TOKEN" | decrypt | trim }}{{ else }}{{ env "PYPI_TOKEN" }}{{ end }}"
|
||||
|
||||
### Replicate
|
||||
export REPLICATE_API_KEY="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "REPLICATE_API_KEY")) }}{{ includeTemplate "secrets/REPLICATE_API_KEY" | decrypt | trim }}{{ else }}{{ env "REPLICATE_API_KEY" }}{{ end }}"
|
||||
|
||||
### Search GPT
|
||||
# Also relies on `OPENAI_API_KEY`
|
||||
export GOOGLE_SEARCH_API_KEY="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "GOOGLE_SEARCH_API_KEY")) }}{{ includeTemplate "secrets/GOOGLE_SEARCH_API_KEY" | decrypt | trim }}{{ else }}{{ env "GOOGLE_SEARCH_API_KEY" }}{{ end }}"
|
||||
export GOOGLE_SEARCH_ID="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "GOOGLE_SEARCH_ID")) }}{{ includeTemplate "secrets/GOOGLE_SEARCH_ID" | decrypt | trim }}{{ else }}{{ env "GOOGLE_SEARCH_ID" }}{{ end }}"
|
||||
|
||||
### Serper.dev
|
||||
export SERP_API_KEY="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "SERP_API_KEY")) }}{{ includeTemplate "secrets/SERP_API_KEY" | decrypt | trim }}{{ else }}{{ env "SERP_API_KEY" }}{{ end }}"
|
||||
|
||||
### Snapcraft
|
||||
export SNAPCRAFT_EMAIL="{{ .user.snapcraft.username }}"
|
||||
export SNAPCRAFT_MACAROON="{{ if (stat (joinPath .chezmoi.sourceDir ".chezmoitemplates" "secrets" "SNAPCRAFT_MACAROON")) }}{{ includeTemplate "secrets/SNAPCRAFT_MACAROON" | decrypt | trim }}{{ else }}{{ env "SNAPCRAFT_MACAROON" }}{{ end }}"
|
||||
|
|
28
home/dot_local/bin/executable_setup-firewall
Normal file
28
home/dot_local/bin/executable_setup-firewall
Normal file
|
@ -0,0 +1,28 @@
|
|||
#!/usr/bin/env bash
|
||||
# @file ~/.local/bin/setup-firewall
|
||||
# @brief Setup and enable the firewall
|
||||
# @description
|
||||
# This script sets up and configures the firewall. On Linux systems, it prefers `firewall-cmd` and, if that is not available,
|
||||
# it uses `ufw`. By default, it allows outgoing traffic and denies incoming traffic.
|
||||
#
|
||||
# ## CloudFlare
|
||||
#
|
||||
# The script will allow incoming traffic on port 80 and 443 from any CloudFlare IP address. The logic was adapted from
|
||||
# [cloudflare-ufw](https://github.com/Paul-Reed/cloudflare-ufw).
|
||||
|
||||
if command -v firewall-cmd > /dev/null; then
|
||||
echo "firewall-cmd detected - preferring this over UFW"
|
||||
elif command -v ufw > /dev/null; then
|
||||
### Deny incoming and allow outgoing
|
||||
sudo ufw default deny incoming
|
||||
sudo ufw default allow outgoing
|
||||
|
||||
### Allow CloudFlare IPs to connect to port 80 and 443
|
||||
for CF_IP in `curl -sw '\n' https://www.cloudflare.com/ips-v{4,6}`; do
|
||||
sudo ufw allow proto tcp from "$CF_IP" to any port 80,443 comment 'CloudFlare IP'
|
||||
done
|
||||
|
||||
### Enable / reload the firewall
|
||||
sudo ufw enable
|
||||
sudo ufw reload
|
||||
fi
|
48
home/dot_local/bin/gpt/executable_agentgpt
Normal file
48
home/dot_local/bin/gpt/executable_agentgpt
Normal file
|
@ -0,0 +1,48 @@
|
|||
#!/usr/bin/env bash
|
||||
# @file ~/.local/bin/gpt/agentgpt
|
||||
# @brief Setup and launch AgentGPT
|
||||
# @description
|
||||
# This script is a script that will automatically setup and launch [AgentGPT](https://github.com/reworkd/AgentGPT).
|
||||
# AgentGPT allows you to assemble, configure, and deploy autonomous AI agents in your browser.
|
||||
|
||||
### Ensure repository is cloned to ~/.local/share/shortgpt
|
||||
if [ ! -d "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt" ]; then
|
||||
git clone https://github.com/reworkd/AgentGPT.git "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt"
|
||||
fi
|
||||
|
||||
### Set working directory
|
||||
cd "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt"
|
||||
|
||||
### Copy .env files
|
||||
if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/agentgpt/next/.env" ]; then
|
||||
cp -f "${XDG_CONFIG_HOME:-$HOME/.config}/agentgpt/next/.env" "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt/next/.env"
|
||||
fi
|
||||
if [ -f "${XDG_CONFIG_HOME:-$HOME/.config}/agentgpt/platform/.env" ]; then
|
||||
cp -f "${XDG_CONFIG_HOME:-$HOME/.config}/agentgpt/platform/.env" "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt/platform/.env"
|
||||
fi
|
||||
|
||||
### Ensure port 8080 is available
|
||||
kill -9 $(lsof -t -i:8080) || EXIT_CODE=$?
|
||||
if [ -n "$EXIT_CODE" ]; then
|
||||
echo "No processes were killed (while ensuring any process listening on port 8080 is killed)"
|
||||
else
|
||||
echo "Killed process listening on port 8080"
|
||||
fi
|
||||
|
||||
### Run the setup script
|
||||
echo | bash "${XDG_DATA_HOME:-$HOME/.local/share}/agentgpt/setup.sh" &
|
||||
|
||||
### Wait until localhost:3000 is available (max. wait of 20 minutes)
|
||||
echo "Waiting for localhost:3000 to become available.."
|
||||
timeout 1200 bash -c 'until printf "" 2>>/dev/null >>/dev/tcp/$0/$1; do sleep 1; done' localhost 3000
|
||||
echo "localhost:3000 is now available!"
|
||||
|
||||
### Open the website
|
||||
WEB_APP_URL="http://127.0.0.1:3000"
|
||||
if command -v xdg-open > /dev/null; then
|
||||
xdg-open "$WEB_APP_URL"
|
||||
elif command -v open && [ -d /Applications ]; then
|
||||
open "$WEB_APP_URL"
|
||||
else
|
||||
echo "Open $WEB_APP_URL in a web browser"
|
||||
fi
|
50
home/dot_local/bin/gpt/executable_localgpt
Normal file
50
home/dot_local/bin/gpt/executable_localgpt
Normal file
|
@ -0,0 +1,50 @@
|
|||
#!/usr/bin/env bash
|
||||
# @file ~/.local/bin/gpt/localgpt
|
||||
# @brief Setup and launch localGPT
|
||||
# @description
|
||||
# This script is a script that will automatically setup and launch [localGPT](https://github.com/PromtEngineer/localGPT).
|
||||
# Chat with your documents on your local device using GPT models. No data leaves your device and 100% private.
|
||||
|
||||
|
||||
### Ensure repository is cloned to ~/.local/share/localgpt
|
||||
if [ ! -d "${XDG_DATA_HOME:-$HOME/.local/share}/localgpt" ]; then
|
||||
git clone https://github.com/PromtEngineer/localGPT.git "${XDG_DATA_HOME:-$HOME/.local/share}/localgpt"
|
||||
fi
|
||||
|
||||
### Set working directory
|
||||
cd "${XDG_DATA_HOME:-$HOME/.local/share}/localgpt"
|
||||
|
||||
### Ensure Conda environment is created
|
||||
echo y | conda create -n localGPT
|
||||
|
||||
### Activate environment
|
||||
conda activate localGPT
|
||||
|
||||
### Install requirements
|
||||
pip3 install -r requirements.txt
|
||||
|
||||
### Ensure port 5111 is available
|
||||
kill -9 $(lsof -t -i:5111) || EXIT_CODE=$?
|
||||
if [ -n "$EXIT_CODE" ]; then
|
||||
echo "No processes were killed (while ensuring any process listening on port 5111 is killed)"
|
||||
else
|
||||
echo "Killed process listening on port 5111"
|
||||
fi
|
||||
|
||||
### Run ShortGPT
|
||||
python3 runShortGPT.py &
|
||||
|
||||
### Wait until localhost:5111 is available (max. wait of 20 minutes)
|
||||
echo "Waiting for localhost:5111 to become available.."
|
||||
timeout 1200 bash -c 'until printf "" 2>>/dev/null >>/dev/tcp/$0/$1; do sleep 1; done' localhost 5111
|
||||
echo "localhost:5111 is now available!"
|
||||
|
||||
### Open the website
|
||||
WEB_APP_URL="http://127.0.0.1:5111"
|
||||
if command -v xdg-open > /dev/null; then
|
||||
xdg-open "$WEB_APP_URL"
|
||||
elif command -v open && [ -d /Applications ]; then
|
||||
open "$WEB_APP_URL"
|
||||
else
|
||||
echo "Open $WEB_APP_URL in a web browser"
|
||||
fi
|
|
@ -1,5 +1,5 @@
|
|||
#!/usr/bin/env bash
|
||||
# @file ~/.local/bin/shortgpt
|
||||
# @file ~/.local/bin/gpt/shortgpt
|
||||
# @brief Setup and launch ShortGPT
|
||||
# @description
|
||||
# This script is a script that will automatically setup and launch [ShortGPT](https://github.com/RayVentura/ShortGPT).
|
||||
|
@ -24,10 +24,28 @@ source .venv/bin/activate
|
|||
### Install requirements
|
||||
pip3 install -r requirements.txt
|
||||
|
||||
### Ensure port 31415 is available
|
||||
kill -9 $(lsof -t -i:31415) || EXIT_CODE=$?
|
||||
if [ -n "$EXIT_CODE" ]; then
|
||||
echo "No processes were killed (while ensuring any process listening on port 31415 is killed)"
|
||||
else
|
||||
echo "Killed process listening on port 31415"
|
||||
fi
|
||||
|
||||
### Run ShortGPT
|
||||
python3 runShortGPT.py &
|
||||
|
||||
### Wait 5 seconds and open expected web address
|
||||
echo "Waiting for shortGPT website to be available before opening it in a web browser"
|
||||
sleep 5
|
||||
open http://127.0.0.1:31415
|
||||
### Wait until localhost:31415 is available (max. wait of 20 minutes)
|
||||
echo "Waiting for localhost:31415 to become available.."
|
||||
timeout 1200 bash -c 'until printf "" 2>>/dev/null >>/dev/tcp/$0/$1; do sleep 1; done' localhost 31415
|
||||
echo "localhost:31415 is now available!"
|
||||
|
||||
### Open the website
|
||||
WEB_APP_URL="http://127.0.0.1:31415"
|
||||
if command -v xdg-open > /dev/null; then
|
||||
xdg-open "$WEB_APP_URL"
|
||||
elif command -v open && [ -d /Applications ]; then
|
||||
open "$WEB_APP_URL"
|
||||
else
|
||||
echo "Open $WEB_APP_URL in a web browser"
|
||||
fi
|
|
@ -444,6 +444,43 @@ if [ -f "$ASDF_DATA_DIR/plugins/java/set-java-home.zsh" ]; then
|
|||
. "$ASDF_DATA_DIR/plugins/java/set-java-home.zsh"
|
||||
fi
|
||||
|
||||
### Mamba Forge (Faster Conda Drop-In Replacement)
|
||||
# TODO: Add support for Linux
|
||||
if [ -f /usr/local/Caskroom/mambaforge/base/bin/conda ]; then
|
||||
# >>> conda initialize >>>
|
||||
# !! Contents within this block are managed by 'conda init' !!
|
||||
__conda_setup="$('/usr/local/Caskroom/mambaforge/base/bin/conda' 'shell.zsh' 'hook' 2> /dev/null)"
|
||||
if [ $? -eq 0 ]; then
|
||||
eval "$__conda_setup"
|
||||
else
|
||||
if [ -f "/usr/local/Caskroom/mambaforge/base/etc/profile.d/conda.sh" ]; then
|
||||
. "/usr/local/Caskroom/mambaforge/base/etc/profile.d/conda.sh"
|
||||
else
|
||||
export PATH="/usr/local/Caskroom/mambaforge/base/bin:$PATH"
|
||||
fi
|
||||
fi
|
||||
unset __conda_setup
|
||||
# <<< conda initialize <<<
|
||||
fi
|
||||
|
||||
### Micro-Mamba
|
||||
# Generate command: micromamba shell init -s zsh -p "${XDG_DATA_HOME:-$HOME/.local/share}/micromamba"
|
||||
# TODO: Ensure Linux support
|
||||
if [ -f /usr/local/bin/micromamba ]; then
|
||||
# >>> mamba initialize >>>
|
||||
# !! Contents within this block are managed by 'mamba init' !!
|
||||
export MAMBA_EXE='/usr/local/bin/micromamba';
|
||||
export MAMBA_ROOT_PREFIX="${XDG_DATA_HOME:-$HOME/.local/share}/micromamba";
|
||||
__mamba_setup="$("$MAMBA_EXE" shell hook --shell zsh --root-prefix "$MAMBA_ROOT_PREFIX" 2> /dev/null)"
|
||||
if [ $? -eq 0 ]; then
|
||||
eval "$__mamba_setup"
|
||||
else
|
||||
alias micromamba="$MAMBA_EXE" # Fallback on help from mamba activate
|
||||
fi
|
||||
unset __mamba_setup
|
||||
# <<< mamba initialize <<<
|
||||
fi
|
||||
|
||||
### Navi (Ctrl+G)
|
||||
if command -v navi > /dev/null; then
|
||||
eval "$(navi widget zsh)"
|
||||
|
|
18
software.yml
18
software.yml
|
@ -435,6 +435,8 @@ softwarePackages:
|
|||
_bin: tomcat
|
||||
_github: https://github.com/apache/tomcat
|
||||
_name: Tomcat
|
||||
_post:darwin: sed 's/8080/8180/g' /usr/local/etc/tomcat/server.xml > /usr/local/etc/tomcat/server.xml
|
||||
_post:linux: sed 's/8080/8180/g' /usr/local/etc/tomcat/server.xml > /usr/local/etc/tomcat/server.xml
|
||||
_service: tomcat
|
||||
apt: tomcat
|
||||
brew: tomcat
|
||||
|
@ -8437,7 +8439,7 @@ softwarePackages:
|
|||
_bin: backup
|
||||
_github: https://github.com/backup/backup
|
||||
_name: Backup
|
||||
gem: backup
|
||||
gem: backup -v5.0.0.beta.1
|
||||
fastlane:
|
||||
_bin: fastlane
|
||||
_github: https://github.com/fastlane/fastlane
|
||||
|
@ -8863,6 +8865,20 @@ softwarePackages:
|
|||
cask: sparkleshare
|
||||
choco: sparkleshare
|
||||
flatpak: org.sparkleshare.SparkleShare
|
||||
mambaforge:
|
||||
_bin: conda
|
||||
_github: https://github.com/mamba-org/mamba
|
||||
_name: Mamba Forge
|
||||
_post: echo y | conda update -n base -c conda-forge conda
|
||||
cask: mambaforge
|
||||
choco: mambaforge
|
||||
script:linux: bash <(curl -L -O "https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-$(uname)-$(uname -m).sh")
|
||||
micromamba:
|
||||
_bin: micromamba
|
||||
_github: https://github.com/mamba-org/mamba
|
||||
_name: MicroMamba
|
||||
_post: micromamba self-update
|
||||
brew: micromamba
|
||||
microsoft-teams:
|
||||
_bin: teams
|
||||
_desc: '[Microsoft Teams](https://www.microsoft.com/en-us/microsoft-teams/group-chat-software) is a proprietary business communication platform developed by Microsoft, as part of the Microsoft 365 family of products. Teams primarily competes with the similar service Slack, offering workspace chat and videoconferencing, file storage, and application integration.'
|
||||
|
|
Loading…
Reference in a new issue