From 6e95380676771906c84145a6c892ecba0d6f46c1 Mon Sep 17 00:00:00 2001 From: Sergey Volkov Date: Tue, 9 Jul 2024 11:46:06 +0200 Subject: [PATCH] Revert "add nix flake to generate website with pelican" This reverts commit 982841ec797da13d8d5a6f83ade4f8261eb2384a. --- .github/workflows/build.yml | 27 ---------------- content/posts/post1.md | 5 --- content/posts/post2.md | 5 --- flake.lock | 61 ------------------------------------- flake.nix | 26 ---------------- index.html | 1 + pelicanconf.py | 27 ---------------- publishconf.py | 15 --------- 8 files changed, 1 insertion(+), 166 deletions(-) delete mode 100644 .github/workflows/build.yml delete mode 100644 content/posts/post1.md delete mode 100644 content/posts/post2.md delete mode 100644 flake.lock delete mode 100644 flake.nix create mode 100644 index.html delete mode 100644 pelicanconf.py delete mode 100644 publishconf.py diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml deleted file mode 100644 index c800148..0000000 --- a/.github/workflows/build.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: Build and Deploy - -on: - push: - branches: - - main # Adjust this as needed - -jobs: - build: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v3 - - - name: Set up Nix - uses: cachix/install-nix-action@v16 - with: - nix_path: nixpkgs=channel:nixos-unstable - - - name: Build site - run: nix build .#defaultPackage.${{ matrix.system }} --print-build-logs - - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.PERSONAL_PAGES_ACCESS }} - publish_dir: ./output diff --git a/content/posts/post1.md b/content/posts/post1.md deleted file mode 100644 index a520ad2..0000000 --- a/content/posts/post1.md +++ /dev/null @@ -1,5 +0,0 @@ -Title: My First Post -Date: 2023-01-01 -Category: Test - -This is the content of my first post. diff --git a/content/posts/post2.md b/content/posts/post2.md deleted file mode 100644 index a0ba19f..0000000 --- a/content/posts/post2.md +++ /dev/null @@ -1,5 +0,0 @@ -Title: My Second Post -Date: 2023-01-02 -Category: Test - -This is the content of my second post. diff --git a/flake.lock b/flake.lock deleted file mode 100644 index 74f0ff4..0000000 --- a/flake.lock +++ /dev/null @@ -1,61 +0,0 @@ -{ - "nodes": { - "flake-utils": { - "inputs": { - "systems": "systems" - }, - "locked": { - "lastModified": 1710146030, - "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "nixpkgs": { - "locked": { - "lastModified": 1720418205, - "narHash": "sha256-cPJoFPXU44GlhWg4pUk9oUPqurPlCFZ11ZQPk21GTPU=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "655a58a72a6601292512670343087c2d75d859c1", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-unstable", - "repo": "nixpkgs", - "type": "github" - } - }, - "root": { - "inputs": { - "flake-utils": "flake-utils", - "nixpkgs": "nixpkgs" - } - }, - "systems": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - } - }, - "root": "root", - "version": 7 -} diff --git a/flake.nix b/flake.nix deleted file mode 100644 index f168158..0000000 --- a/flake.nix +++ /dev/null @@ -1,26 +0,0 @@ -{ - description = "A flake to build a Pelican static site"; - - inputs = { - nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; - flake-utils.url = "github:numtide/flake-utils"; - }; - - outputs = { self, nixpkgs, flake-utils }: flake-utils.lib.eachDefaultSystem (system: - let - pkgs = import nixpkgs { inherit system; }; - in { - devShell = pkgs.mkShell { - buildInputs = [ - pkgs.python310 - pkgs.python310Packages.pelican - pkgs.python310Packages.markdown - ]; - }; - - defaultPackage = pkgs.writeShellScriptBin "build-site" '' - export PATH=$PATH:${pkgs.python310Packages.pelican}/bin - pelican content -o output -s pelicanconf.py - ''; - }); -} diff --git a/index.html b/index.html new file mode 100644 index 0000000..3fa0d4b --- /dev/null +++ b/index.html @@ -0,0 +1 @@ +Hello, World diff --git a/pelicanconf.py b/pelicanconf.py deleted file mode 100644 index f131460..0000000 --- a/pelicanconf.py +++ /dev/null @@ -1,27 +0,0 @@ -AUTHOR = 'Sergei Volkov' -SITENAME = 'My Pelican Site' -SITEURL = '' - -PATH = 'content' - -TIMEZONE = 'Europe/Berlin' - -DEFAULT_LANG = 'en' - -# Feed generation is usually not desired when developing -FEED_ALL_ATOM = None -CATEGORY_FEED_ATOM = None -TRANSLATION_FEED_ATOM = None -AUTHOR_FEED_ATOM = None -AUTHOR_FEED_RSS = None - -# Blogroll -LINKS = (('Pelican', 'https://getpelican.com/'),) - -# Social widget -#SOCIAL = (('You can add links in your config file', '#'),) - -DEFAULT_PAGINATION = 10 - -# Uncomment following line if you want document-relative URLs when developing -#RELATIVE_URLS = True diff --git a/publishconf.py b/publishconf.py deleted file mode 100644 index a110254..0000000 --- a/publishconf.py +++ /dev/null @@ -1,15 +0,0 @@ -import os -import pelicanconf - -#SITEURL = 'https://taranarmo.github.io/' -RELATIVE_URLS = False - -FEED_ALL_ATOM = 'feeds/all.atom.xml' -CATEGORY_FEED_ATOM = 'feeds/{slug}.atom.xml' - -DELETE_OUTPUT_DIRECTORY = True - -# Following items are often useful when publishing - -#DISQUS_SITENAME = "" -#GOOGLE_ANALYTICS = ""