The website is built with Hugo.
-
Go to the
contentfolder and create a folder for your club. -
A sample club has been given, so copy all the files in that sample club to the newly created folder.
-
In every
_index.mdchange thetype: club_name/to onetype:your_Club_name/ -
Go back to the root directory
-
Now go to
layoutsfolder, -
Cooy the sample folder given.
-
Rename it to be your club name.
-
Cd into the content folder and copy the sample
club_namefolder. -
Rename it to the desired name. The path reach your clubs website now is
localhost:xxxx/clubs/club_name. (xxx is your port number on the local machine. Typcially it is 1313 for this.) -
grep -r club_namein the content directory and change every instance of it in your folder to that of your folder name -
Go back to the root.
-
cd into
dataand copy the sampleclub_namefolder. -
Rename it to the same folder name you gaver earlier for content
-
grep -r club_namein the data directory and change every instance of it in your folder to that of your folder name -
team.ymlcontains the memebers of the club, modify it accordingly. -
activities.ymlcontains the list of major events your club does and gets listed in the homepage of your club. -
event.ymlshows a list of events conducted and gets displayed as a gallery, on the events page. -
Modify the
titleandtypeinevent.ymlto reflect the events inactivities.yml. -
Go back to root.
-
cd into
layoutsand copy the sampleclub_namefolder and paste it in the same directory while replacingclub_namewith your club name. -
grep -r club_namein the content directory and change every instance of it in your folder to that of your folder name -
Go to
config/_default/config.toml -
Copy the
menu.club_namesection and paste it again. -
In the pasted section replace the
club_namewith your club -
Go to
layoutsand cd into your club directory, andgrep -r "header". -
Replace every instance of
club_namewith that of your club name.
-
We use,
Hugoa static site generater to generate the website. -
Install Hugo
-
Install the theme, instructions available here.
-
Make sure to install the theme into the right dir,
git clone https://github.com/themefisher/kross-hugo.git themes/kross-hugo-portfolio-template/ -
Run
hugo serverto run the server on your local machine. Execute this command in the root directory of the project. -
If you have drafts, then run
hugo server -Dto view them. Do not keep drafts, and set the value toFalsewhen you're done as they do not get deployed on the site. -
Make sure to have the latest version Hugo installed.
- Run
hugo new event_name.mdin the/content/your-club-name/archive. - All the content posts are written in Markdown, and you can look into the Hugo Documentation for more details.
- Modify the
event.ylfile in the/data/your-club-name/, and add a picture for that event. - Make a new entry directly below the old ones, and give it a picture, and link it to the event-post created in the archive section done earlier. You can do a hardlink if you want(site is deployed on www.clubs.iiit.ac.in/clubs/your-club-name), but preferably make it a relative link, with the link being
{{< ref "/your-club-name/archive/my-post" >}}. - Add the relavant
typefor it. - If you want to add more than one picture make a seperate entry in `activities,yml
- Go to
layouts/your_club/index.htmland modify the files over there - Go to
data\your_club\homepage.ymland modify the Hugo variables from there. - Make sure to go to
layouts/partials/club_name/header.htmland change the home path to your club name fromclub_nameThe names and the rest are pretty self-explanatory. In case you don't like it, you are free to rewriteindex.htmlhowever you like as a normal html file. - Make sure to have the latest version Hugo installed. I'm currently running v0.59.1.
- Take a look at data.
Raise a GitHub issue, and I'll get back to you within a day.