From 9099f089b9a89b27045f87921b0562b295770956 Mon Sep 17 00:00:00 2001 From: Asmir A Date: Tue, 14 Nov 2023 14:17:08 +0100 Subject: [PATCH] repo: add skelet --- .gitignore | 2 ++ .nixd.json | 1 + config.toml | 23 +++++++++++++++++++++++ content/_index.md | 15 +++++++++++++++ flake.lock | 44 +++++++++++++++++++++++++++++++++++++++++++ flake.nix | 47 ++++++++++++++++++++++++++++++++++++++++++++++ result | 1 + templates/.gitkeep | 0 8 files changed, 133 insertions(+) create mode 100644 .gitignore create mode 100644 .nixd.json create mode 100644 config.toml create mode 100644 content/_index.md create mode 100644 flake.lock create mode 100644 flake.nix create mode 120000 result create mode 100644 templates/.gitkeep diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..df57fd0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +public/ +result/ diff --git a/.nixd.json b/.nixd.json new file mode 100644 index 0000000..379d297 --- /dev/null +++ b/.nixd.json @@ -0,0 +1 @@ +{"formatting":{"command":"alejandra"}} diff --git a/config.toml b/config.toml new file mode 100644 index 0000000..97c55de --- /dev/null +++ b/config.toml @@ -0,0 +1,23 @@ +# The URL the site will be built for +base_url = "https://project-cloud.net" + +# Whether to automatically compile all Sass files in the sass directory +compile_sass = true + +# Whether to build a search index to be used later on by a JavaScript library +build_search_index = false + +theme = "anemone" + +[markdown] +highlight_code = true + +[extra] +list_pages = true +header_nav = [ + { url = "/", name_en = "/home/"}, + { url = "/blog", name_en = "/blog/"}, + { url = "https://git.project-cloud.net", name_en = "/git/"}, + { url = "https://cloud.project-cloud.net", name_en = "/cloud/"} +] + diff --git a/content/_index.md b/content/_index.md new file mode 100644 index 0000000..541a8d3 --- /dev/null +++ b/content/_index.md @@ -0,0 +1,15 @@ ++++ ++++ + +## Project Cloud + +Cloud and blog platform for personal and consulting projects. + + +## Public Key + +WP + +## Contact +- Email: [asmir.abdulahovic@gmail.com](mailto:asmir.abdulahovic@gmail.com) + diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..a7641e8 --- /dev/null +++ b/flake.lock @@ -0,0 +1,44 @@ +{ + "nodes": { + "nixpkgs": { + "locked": { + "lastModified": 1699725108, + "narHash": "sha256-NTiPW4jRC+9puakU4Vi8WpFEirhp92kTOSThuZke+FA=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "911ad1e67f458b6bcf0278fa85e33bb9924fed7e", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "root": { + "inputs": { + "nixpkgs": "nixpkgs", + "theme_anemone": "theme_anemone" + } + }, + "theme_anemone": { + "flake": false, + "locked": { + "lastModified": 1699399376, + "narHash": "sha256-u2baLVhc/tWd9h9+g9vKBN1m4qG23uL1HUizFigOJXw=", + "owner": "Speyll", + "repo": "anemone", + "rev": "565a6e84e3054a45ec31729125801ab1f403c936", + "type": "github" + }, + "original": { + "owner": "Speyll", + "repo": "anemone", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..426f19f --- /dev/null +++ b/flake.nix @@ -0,0 +1,47 @@ +{ + inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; + inputs.theme_anemone = { + url = "github:Speyll/anemone"; + flake = false; + }; + + outputs = { + self, + nixpkgs, + theme_anemone, + }: let + supportedSystems = ["x86_64-linux" "aarch64-linux"]; + forAllSystems = nixpkgs.lib.genAttrs supportedSystems; + pkgs = forAllSystems (system: nixpkgs.legacyPackages.${system}); + url = "https://project-cloud.net"; + name = "project-cloud"; + theme = theme_anemone; + in { + packages = forAllSystems (system: { + default = pkgs.${system}.stdenv.mkDerivation { + inherit name; + nativeBuildInputs = with pkgs.${system}; [zola]; + + src = ./.; + submodules = true; + + buildPhase = '' + ls ${theme}/ + ln -s ${theme} themes/anemone + zola build -u ${url} + ''; + + installPhase = '' + mkdir $out + cp -r public/ $out/ + ''; + }; + }); + + devShells = forAllSystems (system: { + default = pkgs.${system}.mkShellNoCC { + packages = with pkgs.${system}; [zola]; + }; + }); + }; +} diff --git a/result b/result new file mode 120000 index 0000000..0f0dc0c --- /dev/null +++ b/result @@ -0,0 +1 @@ +/nix/store/1ilgcfm1rjxvvn6ak0zr76n53y3xbwg1-project-cloud \ No newline at end of file diff --git a/templates/.gitkeep b/templates/.gitkeep new file mode 100644 index 0000000..e69de29