From b7823376a88987a56d82507f35b95199ccbb0391 Mon Sep 17 00:00:00 2001 From: Bruno Rocha Date: Sun, 17 Nov 2024 14:09:33 +0000 Subject: [PATCH] Initial commit --- .github/workflows/main.yaml | 44 ++++++++++++++++++++ README.md | 76 +++++++++++++++++++++++++++++++++++ content/2024-10-22-welcome.md | 18 +++++++++ content/about.md | 7 ++++ custom.css | 2 + custom.js | 1 + marmite.yaml | 13 ++++++ 7 files changed, 161 insertions(+) create mode 100644 .github/workflows/main.yaml create mode 100644 README.md create mode 100644 content/2024-10-22-welcome.md create mode 100644 content/about.md create mode 100644 custom.css create mode 100644 custom.js create mode 100644 marmite.yaml diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml new file mode 100644 index 0000000..7a115e9 --- /dev/null +++ b/.github/workflows/main.yaml @@ -0,0 +1,44 @@ +name: GH Pages Deploy + +on: + push: + branches: [main] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +concurrency: + group: "pages" + cancel-in-progress: false + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Checkout 🛎 + uses: actions/checkout@v4 + + - name: Install marmite 🫙 + run: cargo install marmite + + - name: Build site 🏗️ + run: marmite . site --debug + + - name: Setup Pages + uses: actions/configure-pages@v5 + + - name: Upload artifact + uses: actions/upload-pages-artifact@v3 + with: + path: 'site' + + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v4 diff --git a/README.md b/README.md new file mode 100644 index 0000000..c9c7e68 --- /dev/null +++ b/README.md @@ -0,0 +1,76 @@ +# Create your own blog now! + +Your blog will be generated by [marmite](https://rochacbruno.github.io/marmite/) + +
+ + Click to see screenshots + +**Light Mode** +![index-light](https://github.com/user-attachments/assets/ebb177a3-5c28-437f-88d2-2400474dd84c) +![post-light](https://github.com/user-attachments/assets/c4ea0485-efee-438a-82d1-1c8d9b31a3e8) + +**Dark Mode** +![index-dark](https://github.com/user-attachments/assets/c72a9216-e553-4d91-b48e-7b1e913b264f) +![post-dark](https://github.com/user-attachments/assets/61e6aad9-d84d-4e12-9737-ece02ffd39d2) + +
+ +--- + +## Step 1 + +### As a Fork (recommended) + +[CLICK ON FORK BUTTON](https://github.com/rochacbruno/blog/fork) and name your fork `blog`. + +##### Or as a template + +[Click on Use this template](https://github.com/new?template_name=blog&template_owner=rochacbruno&name=blog&description=Blog%20generated%20with%20Marmite) and name your new repo `blog` + +## Step 2 + +Access https://github.com/YOURUSER/blog/actions and click the green button to enable actions. + +## Step 3 + +Access https://github.com/YOURUSER/blog/settings/pages and set the +pages source to **Github Actions** + +## Step 4 + +Then edit the `marmite.yaml` with your own information. (IMPORTANT! change the `url:..` field to match your own repo) + +If you want to enable comments on the blog [read this](https://rochacbruno.github.io/marmite/enabling-comments.html) + +## Step 5 + +Commit and see the Github Actions building a blog for you. + +Your blog will be published at https://YOURUSER.github.io/blog + +You can add add [custom domain](https://docs.github.com/en/pages/configuring-a-custom-domain-for-your-github-pages-site/managing-a-custom-domain-for-your-github-pages-site) later + +You can customize `css` on `custom.css`, `JS` on `custom.js` and custom themes and other customization options are explained on [customization page](https://rochacbruno.github.io/marmite/tag/customization.html) + +--- + + +## Building locally + +```console +$ git clone git@github.com:YOURUSER/blog.git +$ cd blog +``` + +```console +$ cargo install marmite +``` + +```console +$ marmite . site +Site generated at: /site/ +``` + +Learn more on [marmite](https://rochacbruno.github.io/marmite/) + diff --git a/content/2024-10-22-welcome.md b/content/2024-10-22-welcome.md new file mode 100644 index 0000000..71bdd53 --- /dev/null +++ b/content/2024-10-22-welcome.md @@ -0,0 +1,18 @@ +--- +tags: welcome, blog, marmite +--- + +# Welcome to your blog + +This is your first post! + +Edit it and start blogging! + + +Markdown Formatting: + +https://rochacbruno.github.io/marmite/markdown-format.html + +Theme customization + +https://rochacbruno.github.io/marmite/customizing-templates.html diff --git a/content/about.md b/content/about.md new file mode 100644 index 0000000..bfe4c7e --- /dev/null +++ b/content/about.md @@ -0,0 +1,7 @@ +# About you + +Talk about you! + +Use all markdown + +read more on https://rochacbruno.github.io/marmite/markdown-format.html diff --git a/custom.css b/custom.css new file mode 100644 index 0000000..1f8ddec --- /dev/null +++ b/custom.css @@ -0,0 +1,2 @@ +/* Customize me */ +/* picocss.com */ diff --git a/custom.js b/custom.js new file mode 100644 index 0000000..b68410e --- /dev/null +++ b/custom.js @@ -0,0 +1 @@ +console.log("Hello from marmite"); diff --git a/marmite.yaml b/marmite.yaml new file mode 100644 index 0000000..24e5c8e --- /dev/null +++ b/marmite.yaml @@ -0,0 +1,13 @@ +name: Your Blog +tagline: Things you talk about +url: https://YOURUSER.github.io/blog +menu: + - ["About", "about.html"] + - ["Pages", "pages.html"] + - ["Tags", "tags.html"] + - ["Follow me", "https://mastodon.social/@YOURUSER"] + - ["Github", "https://github.com/rochacbruno/marmite"] + + +# More options available to customize the website +# read on https://rochacbruno.github.io/marmite/tag/customization.html