-
Notifications
You must be signed in to change notification settings - Fork 4
Configuring GitHub
DanPeled edited this page Aug 27, 2024
·
5 revisions
To get your project started, fork this repository by pressing the Fork button located on the top of this repository page.
In order to set up Github Pages hosting, u can deploy your HTML website from the code by either running the ./gh-deploy bash script, or deploy manually:
In the root folder, run the gh-deploy.sh file in order to push onto the ghpages branch in your repository.
In order to make it work:
- Your root folder will have to be linked to a git repository remote
- Modify the
gh-deploy.shcommands to either include or disclude the<base href="/">on your code (Discluded by default)
In order to deploy to GitHub Pages, you will need to do the following steps:
- Run the
flutter build web --web-renderer htmlcommand in the root folder of your project. - In the
build/web/index.htmlfile, remove the line that says :<base href="/">(IF YOU WONT REMOVE THIS LINE, YOUR WEBSITE WILL NOT WORK ON DEFAULT) - Push the
build/webdir's content into a GitHub repo / branch and enable github pages to it.
After deploying your initial website, navigate to your GitHub's repository settings, and under Pages choose
-
Deploy From a branchas the source - the
ghpagesbranch as the branch to deploy from