如何使用 Git 部署和同步原型 Clojurescript 应用程序?
How to deploy and sync a prototype Clojurescript app with Git?
我一直在使用 figwheel 编写 Clojurescript 应用程序。我间歇性地将我的代码推送到 Git 存储库。
我希望人们能够在他们的浏览器中试用我推送的最新版本。
我以前使用 AWS EC2 实例来托管 javascript 应用程序,但每次我想更新它们时都必须手动 cp
我的代码。
有没有方便的方法来部署和同步 cljs 浏览器应用 Git?
Github 页面对于托管页面非常方便,因为它在您的存储库的分支 gh-pages
之外提供内容。
http(s)://username.github.io/projectname
我喜欢使用 deploy.sh 脚本:
#!/bin/bash
set -e
cd $(dirname [=10=])
lein do clean, cljsbuild once min
cd resources/public
git init
git add .
git commit -m "Deploy to GitHub Pages"
git push --force --quiet "git@github.com:timothypratley/pirates.git" master:gh-pages
rm -fr resources/public/.git
您还可以指定一个目录:
https://github.com/blog/2228-simpler-github-pages-publishing
如果您需要更多功能,Firebase 和 Heroku 是不错的选择。
我一直在使用 figwheel 编写 Clojurescript 应用程序。我间歇性地将我的代码推送到 Git 存储库。 我希望人们能够在他们的浏览器中试用我推送的最新版本。
我以前使用 AWS EC2 实例来托管 javascript 应用程序,但每次我想更新它们时都必须手动 cp
我的代码。
有没有方便的方法来部署和同步 cljs 浏览器应用 Git?
Github 页面对于托管页面非常方便,因为它在您的存储库的分支 gh-pages
之外提供内容。
http(s)://username.github.io/projectname
我喜欢使用 deploy.sh 脚本:
#!/bin/bash
set -e
cd $(dirname [=10=])
lein do clean, cljsbuild once min
cd resources/public
git init
git add .
git commit -m "Deploy to GitHub Pages"
git push --force --quiet "git@github.com:timothypratley/pirates.git" master:gh-pages
rm -fr resources/public/.git
您还可以指定一个目录: https://github.com/blog/2228-simpler-github-pages-publishing
如果您需要更多功能,Firebase 和 Heroku 是不错的选择。