Skip to content

HackTJ/2020v2

Repository files navigation

HackTJ 7.5

The website for HackTJ 7.5, held on December 12th-13th, 2020.

Setup

  • yarn install

Development

We use ReactJS.

What to Change

Deployment

  • yarn run start: starts a server on port 3000 and watches files for changes, compiling them on the fly
  • yarn run build: compiles all files to the build/ directory but doesn't watch for changes or start a server
  • yarn run deploy-event: pushes to the gh-pages branch of this repository and deploys the site to hacktj.org/202x
  • yarn run deploy-homepage: pushes to the hacktj.github.io repo and deploys the site to https://hacktj.org
  • yarn run deploy-all: shortcut for both yarn run deploy-event and yarn run deploy-homepage

In the case that one of the endpoints (/2020 or /) doesn't work but the other does, immediately set up a hardcoded redirect in the nonfunctional repository to redirect to the correct site.

Notes for next year

  • click "Use this template" (next to the clone or download dropdown) and name the new repository 2021, under the HackTJ organization—that way it will be displayed on our website at https://hacktj.org/2021 while leaving the old website up at https://hacktj.org/2020
  • all of the deploy commands involve running the switch script in this repository
    • if you notice that this script deletes the content of either public/index.html or src/App.js, immediately quit the deploy script and restore the contents with git and retry the yarn script until it works
  • the deploy-event script doesn't commit the source code to the repository's master branch, it only commits the built code
    • you should commit the source code to the master branch each time you deploy
      • before you commit to master, always make sure you run yarn run switch-event
  • don't run git pull after yarn run switch-homepage
    • only pull when you're set up for the event repository