From 50f32de7585d6515840752300bdc3843d14bf40c Mon Sep 17 00:00:00 2001 From: Rohan Deshpande Date: Thu, 27 Feb 2025 17:41:32 -0800 Subject: [PATCH] first commit --- .hugo_build.lock | 0 archetypes/default.md | 5 ++ content/Life_in_college.md | 8 +++ content/_index.md | 35 +++++++++++ content/about.md | 10 ++++ hugo.toml | 6 ++ public/about/index.html | 33 ++++++++++ public/categories/index.html | 30 ++++++++++ public/categories/index.xml | 33 ++++++++++ public/index.html | 63 ++++++++++++++++++++ public/index.xml | 35 +++++++++++ public/life_in_college/index.html | 36 +++++++++++ public/rss.svg | 1 + public/sitemap.xml | 18 ++++++ public/style.css | 45 ++++++++++++++ public/tags/index.html | 30 ++++++++++ public/tags/index.xml | 33 ++++++++++ static/style.css | 45 ++++++++++++++ themes/lugo/.github/workflows/upload.yml | 32 ++++++++++ themes/lugo/README.md | 21 +++++++ themes/lugo/archetypes/default.md | 6 ++ themes/lugo/config.toml | 17 ++++++ themes/lugo/layouts/_default/baseof.html | 36 +++++++++++ themes/lugo/layouts/_default/list.html | 20 +++++++ themes/lugo/layouts/_default/rss.xml | 26 ++++++++ themes/lugo/layouts/_default/single.html | 3 + themes/lugo/layouts/partials/nav.html | 8 +++ themes/lugo/layouts/partials/nextprev.html | 10 ++++ themes/lugo/layouts/partials/taglist.html | 13 ++++ themes/lugo/layouts/shortcodes/hidvid.html | 10 ++++ themes/lugo/layouts/shortcodes/img.html | 20 +++++++ themes/lugo/layouts/shortcodes/tagcloud.html | 3 + themes/lugo/layouts/shortcodes/vid.html | 6 ++ themes/lugo/static/rss.svg | 1 + themes/lugo/static/style.css | 45 ++++++++++++++ 35 files changed, 743 insertions(+) create mode 100644 .hugo_build.lock create mode 100644 archetypes/default.md create mode 100644 content/Life_in_college.md create mode 100644 content/_index.md create mode 100644 content/about.md create mode 100644 hugo.toml create mode 100644 public/about/index.html create mode 100644 public/categories/index.html create mode 100644 public/categories/index.xml create mode 100644 public/index.html create mode 100644 public/index.xml create mode 100644 public/life_in_college/index.html create mode 100644 public/rss.svg create mode 100644 public/sitemap.xml create mode 100644 public/style.css create mode 100644 public/tags/index.html create mode 100644 public/tags/index.xml create mode 100644 static/style.css create mode 100644 themes/lugo/.github/workflows/upload.yml create mode 100644 themes/lugo/README.md create mode 100644 themes/lugo/archetypes/default.md create mode 100644 themes/lugo/config.toml create mode 100644 themes/lugo/layouts/_default/baseof.html create mode 100644 themes/lugo/layouts/_default/list.html create mode 100644 themes/lugo/layouts/_default/rss.xml create mode 100644 themes/lugo/layouts/_default/single.html create mode 100644 themes/lugo/layouts/partials/nav.html create mode 100644 themes/lugo/layouts/partials/nextprev.html create mode 100644 themes/lugo/layouts/partials/taglist.html create mode 100644 themes/lugo/layouts/shortcodes/hidvid.html create mode 100644 themes/lugo/layouts/shortcodes/img.html create mode 100644 themes/lugo/layouts/shortcodes/tagcloud.html create mode 100644 themes/lugo/layouts/shortcodes/vid.html create mode 100644 themes/lugo/static/rss.svg create mode 100644 themes/lugo/static/style.css diff --git a/.hugo_build.lock b/.hugo_build.lock new file mode 100644 index 0000000..e69de29 diff --git a/archetypes/default.md b/archetypes/default.md new file mode 100644 index 0000000..25b6752 --- /dev/null +++ b/archetypes/default.md @@ -0,0 +1,5 @@ ++++ +date = '{{ .Date }}' +draft = true +title = '{{ replace .File.ContentBaseName "-" " " | title }}' ++++ diff --git a/content/Life_in_college.md b/content/Life_in_college.md new file mode 100644 index 0000000..2ec6667 --- /dev/null +++ b/content/Life_in_college.md @@ -0,0 +1,8 @@ ++++ +date = '2025-02-26T23:06:56-08:00' +draft = true +title = 'Life in college' ++++ + +# Beginning +Idk how to really diff --git a/content/_index.md b/content/_index.md new file mode 100644 index 0000000..fd3f204 --- /dev/null +++ b/content/_index.md @@ -0,0 +1,35 @@ ++++ +date = '2025-02-24T10:42:32-08:00' +draft = false +title = 'Rohan' ++++ + +# About me +I'm Rohan Deshpande, a current student at UCLA studying [Computational and Systems Biology](https://casb.ucla.edu/). +Since the UCLA LUG was gracious enough to give me a server, I figured it was about time that I started my own website instead of relying on other platforms. + +This website is a way where I can document my time in college through articles, as well as explaining some stuff. +I want to host more stuff here in the future, such as my in-progress personal knowledge management system, but this can serve as a hub. + + + +## Interests +Some of my interests include: +* Biology +* Chemistry +* Medicine +* Computer Science +* Math +* History +* Geopolitics + +Very spread out. +The history and geopolitics is more of a hobby, but I am interested in getting involved in [systems biology](https://en.wikipedia.org/wiki/Systems_biology) research and using computers to create models of biological processes. +I'd appreciate any guidance involving this, or once I get into a lab and spend some time there I'll write an article. + +## Currently Reading +**My Life: A Spoken Autobiography** by *Fidel Castro* + + +## Articles + diff --git a/content/about.md b/content/about.md new file mode 100644 index 0000000..e159a10 --- /dev/null +++ b/content/about.md @@ -0,0 +1,10 @@ ++++ +date = '2025-02-24T10:20:27-08:00' +draft = false +title = 'First post' ++++ + +# My time + + + diff --git a/hugo.toml b/hugo.toml new file mode 100644 index 0000000..6b3748c --- /dev/null +++ b/hugo.toml @@ -0,0 +1,6 @@ +baseURL = '/' +relativeURLs = true +languageCode = 'en-us' +title = "Rohan's Website" + +theme = 'lugo' diff --git a/public/about/index.html b/public/about/index.html new file mode 100644 index 0000000..2feb323 --- /dev/null +++ b/public/about/index.html @@ -0,0 +1,33 @@ + + + + First Post | Rohan's Website + + + + + + + + + + +
+

First post

+ +
+ + + + + diff --git a/public/categories/index.html b/public/categories/index.html new file mode 100644 index 0000000..fa92d53 --- /dev/null +++ b/public/categories/index.html @@ -0,0 +1,30 @@ + + + + Categories | Rohan's Website + + + + + + + + + + +
+

Categories

+
+ +
    +
+ +
+
+ + + + + diff --git a/public/categories/index.xml b/public/categories/index.xml new file mode 100644 index 0000000..71777d7 --- /dev/null +++ b/public/categories/index.xml @@ -0,0 +1,33 @@ + + + Rohan's Website + //localhost:1313/categories/ + Recent content in Categories on Rohan's Website + Hugo -- gohugo.io + en-us + + + + + + Life_in_college + //localhost:1313/life_in_college/ + Wed, 26 Feb 2025 23:06:56 -0800 + + //localhost:1313/life_in_college/ + <h1 id="test">Test</h1> + + + + + First post + //localhost:1313/about/ + Mon, 24 Feb 2025 10:20:27 -0800 + + //localhost:1313/about/ + <h1 id="my-time">My time</h1> + + + + + diff --git a/public/index.html b/public/index.html new file mode 100644 index 0000000..ce97ae4 --- /dev/null +++ b/public/index.html @@ -0,0 +1,63 @@ + + + + + Rohan's Website + + + + + + + + + + +
+

Rohan

+
+

About me

+

I’m Rohan Deshpande, a current student at UCLA studying Computational and Systems Biology. +Since the UCLA LUG was gracious enough to give me a server, I figured it was about time that I started my own website instead of relying on other platforms.

+

This website is a way where I can document my time in college through articles, as well as explaining some stuff. +I want to host more stuff here in the future, such as my in-progress personal knowledge management system, but this can serve as a hub.

+

Interests

+

Some of my interests include:

+
    +
  • Biology
  • +
  • Chemistry
  • +
  • Medicine
  • +
  • Computer Science
  • +
  • Math
  • +
  • History
  • +
  • Geopolitics
  • +
+

Very spread out. +The history and geopolitics is more of a hobby, but I am interested in getting involved in systems biology research and using computers to create models of biological processes. +I’d appreciate any guidance involving this, or once I get into a lab and spend some time there I’ll write an article.

+

Currently Reading

+

My Life: A Spoken Autobiography by Fidel Castro

+

Articles

+ + + +
+
+ + + + + diff --git a/public/index.xml b/public/index.xml new file mode 100644 index 0000000..a70a686 --- /dev/null +++ b/public/index.xml @@ -0,0 +1,35 @@ + + + Rohan's Website + //localhost:1313/ + Recent content in Rohan on Rohan's Website + Hugo -- gohugo.io + en-us + Mon, 24 Feb 2025 10:42:32 -0800 + + + + + + Life in college + //localhost:1313/life_in_college/ + Wed, 26 Feb 2025 23:06:56 -0800 + + //localhost:1313/life_in_college/ + <h1 id="beginning">Beginning</h1> +<p>Idk how to really</p> + + + + + First post + //localhost:1313/about/ + Mon, 24 Feb 2025 10:20:27 -0800 + + //localhost:1313/about/ + <h1 id="my-time">My time</h1> + + + + + diff --git a/public/life_in_college/index.html b/public/life_in_college/index.html new file mode 100644 index 0000000..d935edf --- /dev/null +++ b/public/life_in_college/index.html @@ -0,0 +1,36 @@ + + + + Life in College | Rohan's Website + + + + + + + + + + +
+

Life in college

+ +
+ + + + + diff --git a/public/rss.svg b/public/rss.svg new file mode 100644 index 0000000..dfda038 --- /dev/null +++ b/public/rss.svg @@ -0,0 +1 @@ + diff --git a/public/sitemap.xml b/public/sitemap.xml new file mode 100644 index 0000000..1420663 --- /dev/null +++ b/public/sitemap.xml @@ -0,0 +1,18 @@ + + + + //localhost:1313/life_in_college/ + 2025-02-26T23:06:56-08:00 + + //localhost:1313/ + 2025-02-24T10:42:32-08:00 + + //localhost:1313/about/ + 2025-02-24T10:20:27-08:00 + + //localhost:1313/categories/ + + //localhost:1313/tags/ + + diff --git a/public/style.css b/public/style.css new file mode 100644 index 0000000..d3b2088 --- /dev/null +++ b/public/style.css @@ -0,0 +1,45 @@ +body { + font-family: sans-serif ; + background: #110000 ; + color: #ccc ; +} + +main { + max-width: 800px ; + margin: auto ; +} + +img { + max-width: 100% ; +} + +header h1 { + text-align: center ; +} + +footer { + text-align: center ; + clear: both ; +} + +/* For TAGLIST.HTML */ +.taglist { + text-align: center ; + clear: both ; +} + +/* For NEXTPREV.HTML */ +#nextprev { + /* The container for both the previous and next articles. */ +} +#prevart { + float: left ; + text-align: left ; +} +#nextart { + float: right ; + text-align: right ; +} +#nextart,#prevart { + max-width: 33% ; +} diff --git a/public/tags/index.html b/public/tags/index.html new file mode 100644 index 0000000..bc57e2f --- /dev/null +++ b/public/tags/index.html @@ -0,0 +1,30 @@ + + + + Tags | Rohan's Website + + + + + + + + + + +
+

Tags

+
+ +
    +
+ +
+
+ + + + + diff --git a/public/tags/index.xml b/public/tags/index.xml new file mode 100644 index 0000000..1687c49 --- /dev/null +++ b/public/tags/index.xml @@ -0,0 +1,33 @@ + + + Rohan's Website + //localhost:1313/tags/ + Recent content in Tags on Rohan's Website + Hugo -- gohugo.io + en-us + + + + + + Life_in_college + //localhost:1313/life_in_college/ + Wed, 26 Feb 2025 23:06:56 -0800 + + //localhost:1313/life_in_college/ + <h1 id="test">Test</h1> + + + + + First post + //localhost:1313/about/ + Mon, 24 Feb 2025 10:20:27 -0800 + + //localhost:1313/about/ + <h1 id="my-time">My time</h1> + + + + + diff --git a/static/style.css b/static/style.css new file mode 100644 index 0000000..d3b2088 --- /dev/null +++ b/static/style.css @@ -0,0 +1,45 @@ +body { + font-family: sans-serif ; + background: #110000 ; + color: #ccc ; +} + +main { + max-width: 800px ; + margin: auto ; +} + +img { + max-width: 100% ; +} + +header h1 { + text-align: center ; +} + +footer { + text-align: center ; + clear: both ; +} + +/* For TAGLIST.HTML */ +.taglist { + text-align: center ; + clear: both ; +} + +/* For NEXTPREV.HTML */ +#nextprev { + /* The container for both the previous and next articles. */ +} +#prevart { + float: left ; + text-align: left ; +} +#nextart { + float: right ; + text-align: right ; +} +#nextart,#prevart { + max-width: 33% ; +} diff --git a/themes/lugo/.github/workflows/upload.yml b/themes/lugo/.github/workflows/upload.yml new file mode 100644 index 0000000..13acfb8 --- /dev/null +++ b/themes/lugo/.github/workflows/upload.yml @@ -0,0 +1,32 @@ +name: CI + +# Controls when the action will run. +on: + # Triggers the workflow on push to master (including merged PRs) + push: + branches: [ master ] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + update: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + - name: Updating website. + uses: appleboy/ssh-action@master + with: + host: lukesmith.xyz + username: lugo + key: ${{ secrets.lugo_ssh }} + passphrase: ${{ secrets.lugo_pass }} + port: 22 + script: | + cd /var/www/lugo + git stash + git pull --force origin master diff --git a/themes/lugo/README.md b/themes/lugo/README.md new file mode 100644 index 0000000..a39a9e8 --- /dev/null +++ b/themes/lugo/README.md @@ -0,0 +1,21 @@ +# Luke's Hugo Theme + +A simple Hugo theme I plan on using for my personal website, [Based.Cooking](https://based.cooking) and [LandChad.net](https://landchad.net). + +## get started + +```sh +hugo new site new-site +cd new-site +git clone https://github.com/lukesmithxyz/lugo themes/lugo +echo "theme = 'lugo'" >> config.toml +cp themes/lugo/static/style.css static/ +``` + +## stuff + +- Makes one RSS feed for the entire site at `/index.xml` +- Stylesheet is in `/style.css` and includes some important stuff for partials. +- If a post is tagged, links to the tags are placed at the bottom of the post. +- `nextprev.html` adds links to the Next and Previous articles to the bottom of a page. +- `taglist.html` links all tags an article is tagged to for related content. diff --git a/themes/lugo/archetypes/default.md b/themes/lugo/archetypes/default.md new file mode 100644 index 0000000..00e77bd --- /dev/null +++ b/themes/lugo/archetypes/default.md @@ -0,0 +1,6 @@ +--- +title: "{{ replace .Name "-" " " | title }}" +date: {{ .Date }} +draft: true +--- + diff --git a/themes/lugo/config.toml b/themes/lugo/config.toml new file mode 100644 index 0000000..e884199 --- /dev/null +++ b/themes/lugo/config.toml @@ -0,0 +1,17 @@ +title = "Website Name" +baseURL = 'https://example.org' +languageCode = 'en-us' + +[params] + # "relatedtext" is the text that appears above the tag list at the bottom of pages. + relatedtext = "Related" + favicon = "/favicon.ico" + + #list items + datesinlist = true + authorsinlist = true + + #footer items + nextprev = true + taglist = true + showrss = true \ No newline at end of file diff --git a/themes/lugo/layouts/_default/baseof.html b/themes/lugo/layouts/_default/baseof.html new file mode 100644 index 0000000..57e17ce --- /dev/null +++ b/themes/lugo/layouts/_default/baseof.html @@ -0,0 +1,36 @@ + + + + {{ if not .IsHome }}{{ .Title | title }} | {{ end }}{{ .Site.Title }} + + + + {{ with .Site.Params.favicon }} + {{ end -}} + + {{ if isset .Params "tags" }} + {{ end -}} + + + + + +{{ if .Site.Menus.main }}{{ partial "nav.html" . }}{{ end -}} +
+

{{ block "title" . }}{{ end }}

+
+{{ block "main" . }} +{{ .Content }} +{{ end }} +{{ if .Param "nextprev" }}{{ partial "nextprev.html" . -}}{{ end -}} +{{ if .Param "taglist" }}{{ partial "taglist.html" . }}{{ end -}} +
+
+{{ block "footer" . }} + +{{ end }} + + diff --git a/themes/lugo/layouts/_default/list.html b/themes/lugo/layouts/_default/list.html new file mode 100644 index 0000000..601fc08 --- /dev/null +++ b/themes/lugo/layouts/_default/list.html @@ -0,0 +1,20 @@ +{{ define "title" -}} +{{ .Title | title }} +{{- end }} +{{ define "main" -}} +{{ .Content }} + +{{- end }} diff --git a/themes/lugo/layouts/_default/rss.xml b/themes/lugo/layouts/_default/rss.xml new file mode 100644 index 0000000..38dbe3d --- /dev/null +++ b/themes/lugo/layouts/_default/rss.xml @@ -0,0 +1,26 @@ + + + {{ .Site.Title }} + {{ .Permalink }} + Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ .Site.Title }} + Hugo -- gohugo.io{{ with .Site.LanguageCode }} + {{.}}{{end}}{{ with .Site.Author.email }} + {{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}}{{ with .Site.Author.email }} + {{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}}{{ with .Site.Copyright }} + {{.}}{{end}}{{ if not .Date.IsZero }} + {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} + {{ with .OutputFormats.Get "RSS" }} + {{ printf "" .Permalink .MediaType | safeHTML }} + {{ end }} + {{ range .Site.RegularPages }} + + {{ .Title }} + {{ .Permalink }} + {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }} + {{ with .Site.Author.email }}{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}} + {{ .Permalink }} + {{- .Content | html -}} + + {{ end }} + + diff --git a/themes/lugo/layouts/_default/single.html b/themes/lugo/layouts/_default/single.html new file mode 100644 index 0000000..56c5a11 --- /dev/null +++ b/themes/lugo/layouts/_default/single.html @@ -0,0 +1,3 @@ +{{ define "title" -}} +{{ .Title }} +{{- end }} diff --git a/themes/lugo/layouts/partials/nav.html b/themes/lugo/layouts/partials/nav.html new file mode 100644 index 0000000..a7318fe --- /dev/null +++ b/themes/lugo/layouts/partials/nav.html @@ -0,0 +1,8 @@ + diff --git a/themes/lugo/layouts/partials/nextprev.html b/themes/lugo/layouts/partials/nextprev.html new file mode 100644 index 0000000..099f16d --- /dev/null +++ b/themes/lugo/layouts/partials/nextprev.html @@ -0,0 +1,10 @@ +{{ if or .Next .Prev -}} +
+{{- with .Prev }} +
Previous:
{{.Title}}
+{{ end -}} +{{- with .Next -}} +
Next:
{{.Title}}
+{{ end -}} +
+{{ end -}} diff --git a/themes/lugo/layouts/partials/taglist.html b/themes/lugo/layouts/partials/taglist.html new file mode 100644 index 0000000..757db6f --- /dev/null +++ b/themes/lugo/layouts/partials/taglist.html @@ -0,0 +1,13 @@ + {{- if isset .Params "tags" -}} + {{- $tagsLen := len .Params.tags -}} + {{- if gt $tagsLen 0 -}} +
+ {{- with .Site.Params.relatedtext }}{{ . }}
{{ end -}} + {{- range $k, $v := .Params.tags -}} + {{- $url := printf "tags/%s" (. | urlize | lower) -}} + {{ . | title }} + {{- if lt $k (sub $tagsLen 1) }} · {{ end -}} + {{- end -}} +
+ {{- end -}} + {{- end }} diff --git a/themes/lugo/layouts/shortcodes/hidvid.html b/themes/lugo/layouts/shortcodes/hidvid.html new file mode 100644 index 0000000..14f592d --- /dev/null +++ b/themes/lugo/layouts/shortcodes/hidvid.html @@ -0,0 +1,10 @@ +
+ Click to reveal video. + +
diff --git a/themes/lugo/layouts/shortcodes/img.html b/themes/lugo/layouts/shortcodes/img.html new file mode 100644 index 0000000..ff7959b --- /dev/null +++ b/themes/lugo/layouts/shortcodes/img.html @@ -0,0 +1,20 @@ + +
+ {{- with .Get "link"}}{{ end -}} + {{.}} + {{- if .Get "link"}}{{ end -}} + {{- with .Get "caption" -}} +
+ {{- . -}} +
+ {{- end -}} +
diff --git a/themes/lugo/layouts/shortcodes/tagcloud.html b/themes/lugo/layouts/shortcodes/tagcloud.html new file mode 100644 index 0000000..0cf0118 --- /dev/null +++ b/themes/lugo/layouts/shortcodes/tagcloud.html @@ -0,0 +1,3 @@ +{{ if isset .Site.Taxonomies "tags" }}{{ if not (eq (len .Site.Taxonomies.tags) 0) }} {{ end }}{{ end }} diff --git a/themes/lugo/layouts/shortcodes/vid.html b/themes/lugo/layouts/shortcodes/vid.html new file mode 100644 index 0000000..4c612fe --- /dev/null +++ b/themes/lugo/layouts/shortcodes/vid.html @@ -0,0 +1,6 @@ + diff --git a/themes/lugo/static/rss.svg b/themes/lugo/static/rss.svg new file mode 100644 index 0000000..dfda038 --- /dev/null +++ b/themes/lugo/static/rss.svg @@ -0,0 +1 @@ + diff --git a/themes/lugo/static/style.css b/themes/lugo/static/style.css new file mode 100644 index 0000000..d3b2088 --- /dev/null +++ b/themes/lugo/static/style.css @@ -0,0 +1,45 @@ +body { + font-family: sans-serif ; + background: #110000 ; + color: #ccc ; +} + +main { + max-width: 800px ; + margin: auto ; +} + +img { + max-width: 100% ; +} + +header h1 { + text-align: center ; +} + +footer { + text-align: center ; + clear: both ; +} + +/* For TAGLIST.HTML */ +.taglist { + text-align: center ; + clear: both ; +} + +/* For NEXTPREV.HTML */ +#nextprev { + /* The container for both the previous and next articles. */ +} +#prevart { + float: left ; + text-align: left ; +} +#nextart { + float: right ; + text-align: right ; +} +#nextart,#prevart { + max-width: 33% ; +}