{"modulePath":"github.com/brevdev/brev-cli","version":"v0.6.337","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package setupscript\n\n## Constants\n\n```go\nconst DefaultSetupScript = `\n#!/bin/bash\n\nset -euo pipefail\n\n####################################################################################\n##### Specify software and dependencies that are required for this project     #####\n#####                                                                          #####\n##### Note:                                                                    #####\n##### The working directory is /home/brev/\u003cPROJECT_FOLDER_NAME\u003e. Execution of  #####\n##### this file happens at this level.                                         #####\n####################################################################################\n\n##### Yarn #####\n# (echo \"\"; echo \"##### Yarn #####\"; echo \"\";)\n# curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add\n# echo \"deb https://dl.yarnpkg.com/debian/ stable main\" | sudo tee /etc/apt/sources.list.d/yarn.list\n# sudo apt update\n# sudo apt install -y yarn\n\n##### Homebrew #####\n# (echo \"\"; echo \"##### Homebrew #####\"; echo \"\";)\n# curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh | bash -\n# echo 'eval \"$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)\"' \u003e\u003e /home/brev/.bash_profile\n# echo 'eval \"$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)\"' \u003e\u003e /home/brev/.zshrc\n# eval \"$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)\"\n\n##### Node v14.x + npm #####\n# (echo \"\"; echo \"##### Node v14.x + npm #####\"; echo \"\";)\n# sudo apt install ca-certificates\n# curl -fsSL https://deb.nodesource.com/setup_14.x | sudo -E bash -\n# sudo apt-get install -y nodejs\n\n# install npm packages globally without sudo\n# modified from https://stackoverflow.com/questions/18088372/how-to-npm-install-global-not-as-root\n# mkdir \"${HOME}/.npm-packages\"\n# printf \"prefix=${HOME}/.npm-packages\" \u003e\u003e $HOME/.npmrc\n# cat \u003c\u003cEOF | tee -a ~/.bashrc | tee -a ~/.zshrc\n# NPM_PACKAGES=\"\\${HOME}/.npm-packages\"\n# NODE_PATH=\"\\${NPM_PACKAGES}/lib/node_modules:\\${NODE_PATH}\"\n# PATH=\"\\${NPM_PACKAGES}/bin:\\${PATH}\"\n# # Unset manpath so we can inherit from /etc/manpath via the ` + \"`manpath`\\n\" + `\n# # command\n# unset MANPATH # delete if you already modified MANPATH elsewhere in your config\n# MANPATH=\"\\${NPM_PACKAGES}/share/man:\\$(manpath)\"\n# EOF\n\n##### Python + Pip + Poetry #####\n# (echo \"\"; echo \"##### Python + Pip + Poetry #####\"; echo \"\";)\n# sudo apt-get install -y python3-distutils\n# sudo apt-get install -y python3-apt\n# curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python3 -\n# curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py\n# python3 get-pip.py\n# rm get-pip.py\n# source $HOME/.poetry/env\n\n##### Golang v16x #####\n# (echo \"\"; echo \"##### Golang v16x #####\"; echo \"\";)\n# wget https://golang.org/dl/go1.16.7.linux-amd64.tar.gz\n# sudo rm -rf /usr/local/go \u0026\u0026 sudo tar -C /usr/local -xzf go1.16.7.linux-amd64.tar.gz\n# echo \"\" | sudo tee -a ~/.bashrc\n# echo \"export PATH=\\$PATH:/usr/local/go/bin\" | sudo tee -a ~/.bashrc\n# source ~/.bashrc\n# echo \"\" | sudo tee -a ~/.zshrc\n# echo \"export PATH=\\$PATH:/usr/local/go/bin\" | sudo tee -a ~/.zshrc\n# source ~/.zshrc\n# rm go1.16.7.linux-amd64.tar.gz\n\n##### Custom commands #####\n# (echo \"\"; echo \"##### Custom commands #####\"; echo \"\";)\n# npm install\n`\n```\n\n## Functions\n\n```go\nfunc GenSetupHunkForLanguage(language, version string) (string, error)\n```\n\n## Types\n\n```go\ntype GoHunk struct {\n\tVersion string\n}\n```\n\n```go\nfunc (gh GoHunk) GetTemplate() (*template.Template, error)\n```\n\n```go\nfunc (gh GoHunk) GetTemplateString() string\n```\n\n```go\nfunc (gh *GoHunk) SetVersion(version string)\n```\n\n```go\nfunc (gh GoHunk) WriteHunk(w io.Writer) error\n```\n\n","path":"github.com/brevdev/brev-cli/pkg/setupscript","name":"setupscript","synopsis":"","isRedistributable":true}
