diff --git a/output/about.html b/output/about.html index 14c031d..25ccdb1 100644 --- a/output/about.html +++ b/output/about.html @@ -3,214 +3,53 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - About Me - + + - +
+ +
Updated: 2025-08-06 Wed 19:16
+

About Me

Table of Contents

-
-

1. About Me ๐Ÿ‘‹

-
+
+

About Me ๐Ÿ‘‹

+

I'm building a personal site using Emacs, Org-mode, and Cloudflare Pages.

@@ -220,9 +59,9 @@ I'm building a personal site using Emacs, Org-mode, and Cloudfl

-
-

2. Interests

-
+
+

Interests

+
  • Linux
  • Open source
  • @@ -231,13 +70,184 @@ I'm building a personal site using Emacs, Org-mode, and Cloudfl
-
-

3. Back to Home

+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Interests

+
+
    +
  • Linux
  • +
  • Open source
  • +
  • Org mode
  • +
  • Static sites
  • +
+
+
+
+

Back to Home

-

Created: 2025-08-06 Wed 15:20

-

Validate

+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
diff --git a/output/assets/org-roam-ui-graph.png b/output/assets/org-roam-ui-graph.png new file mode 100644 index 0000000..c46d6f9 Binary files /dev/null and b/output/assets/org-roam-ui-graph.png differ diff --git a/output/contact.html b/output/contact.html new file mode 100644 index 0000000..29c5adf --- /dev/null +++ b/output/contact.html @@ -0,0 +1,63 @@ + + + + + + +Contact + + + + + + +
+ +
Updated: 2025-08-06 Wed 20:58
+
+
+

Contact

+
+

Contact Using the Following:

+
+

+> LinkedIn: LinkedIn +

+ +

+> GitHub: Github +

+ +

+> Email: +

+ + + +

+Thanks for visiting! +

+
+
+
+
+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
+
+ + diff --git a/output/index.html b/output/index.html index d36f6f3..c77b5e3 100644 --- a/output/index.html +++ b/output/index.html @@ -3,216 +3,30 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - -Welcome to My Org Website +Zaine Qayyum - + + - +
+ +
Updated: 2025-08-06 Wed 22:37
+
-

Welcome to My Org Website

- -
-

1. Hello from Org Mode ๐ŸŒฑ

-
+

Zaine Qayyum

+
+

Welcome! ๐ŸŒฑ

+

-This is a simple homepage built with Emacs Org-mode and published using org-publish. +This is a website built using Emacs Org-mode and published using org-publish.

@@ -221,33 +35,121 @@ Feel free to explore:

-
-

2. Blog Posts

-
+
+

How to publish web pages using org-publish

+

-Here are some placeholder posts: +This website is heavily inspired by some people who have decided to use org-publish as a way to convert org files into html. I came across a few that took the plunge and decided to migrate from platforms like Wordpress and instead opted for a more transparent, text-based workflow.

-
    -
  1. Org Mode Official Site
  2. -
  3. Learn more about me
  4. -
-
-
-
-

3. Contact

-
+

-Feel free to reach out on GitHub: https://github.com/yourusername +There is a Unix philosophy that emphasises building simple and compact code that can be easily maintainable, and following this approach (do one thing well) aligns with this philosophy. +

+ +

+So how does one go about publishing web pages through Emacs's org-publish? The answer is quite simple. You probably will need to have some familiarity with elisp although it's not a must. +

+ +

+The first thing we will want to do is edit our init.el file, which is the initialization file. In this file we want to add the following: +

+ + +
+
+(setq org-publish-project-alist
+    '(("org-notes"
+       :base-directory "~/web"
+       :base-extension "org"
+       :publishing-directory "~/web"
+       :recursive t
+       :publishing-function org-html-publish-to-html
+       :with-author nil
+       :with-creator nil
+       :html-validation-link nil
+       :with-toc t
+       :section-numbers t
+       :html-head "<link rel=\"stylesheet\" href=\"style.css\" />"
+       )
+      ("org-static"
+       :base-directory "~/web"
+       :base-extension "css\\|js\\|png\\|jpg\\|gif"
+       :publishing-directory "~/web/output"
+       :recursive t
+       :publishing-function org-publish-attachment)
+      ("website" :components ("org-notes" "org-static"))))
+
+
+
+ +

+What this snippet of code is doing is it is telling org-publish what configurations we want to use when we end up running the publish command. Under ~/web is where we want to include our files. Let us take a simple example and create an index.org file: +

+ +
+
+#+TITLE: Website Name
+#+OPTIONS: toc:nil num:nil
+#+HTML_HEAD: <link rel="stylesheet" href="style.css">
+
+* Welcome!
+
+This is a simple website
+
+
+
+ +

+There are some metadata at the very top as we can see, these help us customise each page the way we want to. Here I disabled the Table of Contents and section numbers just for this file. We can also create a simple styles.css file in the same directory. +After doing this, we can run the command: +

+ +
+
+M-x org-publish RET website
+
+
+
+ +

+This will generate a html file inside the ~/web/output/ directory, and we can serve this file using any static site generation tools; I recommend python due to it's simplicity: +

+ +
+
+cd ~/web/output
+python3 -m http.server 8000 
+
+
+
+ +

+And there we go! The files are now being hosted on http://localhost:8000/ and we have a fully functioning workflow for converting org files into a static website. +

+
+
+
+

Contact

+
+

+Feel free to reach out on GitHub: https://github.com/zainezq

-

Created: 2025-08-06 Wed 15:20

-

Validate

+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
diff --git a/output/output/output/style.css b/output/output/output/style.css deleted file mode 100644 index 115bc83..0000000 --- a/output/output/output/style.css +++ /dev/null @@ -1,58 +0,0 @@ -:root { - --bg: #ffffff; - --fg: #000000; - --link: #1a0dab; - --heading: #004c99; - --code-bg: #f0f0f0; -} - -body.dark { - --bg: #121212; - --fg: #e0e0e0; - --link: #8ab4f8; - --heading: #7baaf7; - --code-bg: #1e1e1e; -} - -body { - font-family: sans-serif; - max-width: 700px; - margin: 2rem auto; - padding: 1rem; - line-height: 1.6; - background-color: var(--bg); - color: var(--fg); - transition: background-color 0.3s, color 0.3s; -} - -h1, h2, h3 { - color: var(--heading); -} - -a { - color: var(--link); - text-decoration: none; -} - -a:hover { - text-decoration: underline; -} - -pre, code { - background: var(--code-bg); - padding: 0.2em 0.4em; - border-radius: 4px; - font-family: monospace; -} - -/* Toggle button */ -#theme-toggle { - position: fixed; - top: 1rem; - right: 1rem; - padding: 0.4em 0.8em; - background: var(--code-bg); - border: none; - border-radius: 5px; - cursor: pointer; -} diff --git a/output/output/style.css b/output/output/style.css deleted file mode 100644 index 115bc83..0000000 --- a/output/output/style.css +++ /dev/null @@ -1,58 +0,0 @@ -:root { - --bg: #ffffff; - --fg: #000000; - --link: #1a0dab; - --heading: #004c99; - --code-bg: #f0f0f0; -} - -body.dark { - --bg: #121212; - --fg: #e0e0e0; - --link: #8ab4f8; - --heading: #7baaf7; - --code-bg: #1e1e1e; -} - -body { - font-family: sans-serif; - max-width: 700px; - margin: 2rem auto; - padding: 1rem; - line-height: 1.6; - background-color: var(--bg); - color: var(--fg); - transition: background-color 0.3s, color 0.3s; -} - -h1, h2, h3 { - color: var(--heading); -} - -a { - color: var(--link); - text-decoration: none; -} - -a:hover { - text-decoration: underline; -} - -pre, code { - background: var(--code-bg); - padding: 0.2em 0.4em; - border-radius: 4px; - font-family: monospace; -} - -/* Toggle button */ -#theme-toggle { - position: fixed; - top: 1rem; - right: 1rem; - padding: 0.4em 0.8em; - background: var(--code-bg); - border: none; - border-radius: 5px; - cursor: pointer; -} diff --git a/output/output/theme-toggle.js b/output/output/theme-toggle.js deleted file mode 100644 index c3e736a..0000000 --- a/output/output/theme-toggle.js +++ /dev/null @@ -1,34 +0,0 @@ -function setTheme(mode) { - if (mode === 'dark') { - document.body.classList.add('dark'); - localStorage.setItem('theme', 'dark'); - } else { - document.body.classList.remove('dark'); - localStorage.setItem('theme', 'light'); - } -} - -function toggleTheme() { - const current = document.body.classList.contains('dark') ? 'dark' : 'light'; - setTheme(current === 'dark' ? 'light' : 'dark'); -} - -window.addEventListener('DOMContentLoaded', () => { - const saved = localStorage.getItem('theme'); - - // Auto-detect system preference if no saved preference - if (!saved) { - if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) { - setTheme('dark'); - } - } else if (saved === 'dark') { - setTheme('dark'); - } - - // Add the toggle button - const button = document.createElement('button'); - button.id = 'theme-toggle'; - button.innerText = 'Toggle Theme'; - button.onclick = toggleTheme; - document.body.appendChild(button); -}); diff --git a/output/posts.html b/output/posts.html new file mode 100644 index 0000000..c4c347b --- /dev/null +++ b/output/posts.html @@ -0,0 +1,55 @@ + + + + + + +Posts + + + + + + +
+ +
Updated: 2025-08-06 Wed 21:03
+
+
+

Posts

+
+

Links

+
+
+
+

Posts Introduction   intro

+
+ + +
+

Zettelkasten Method   education

+
+

+<2025-08-06 Wed> +

+
+
+
+
+
+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
+
+ + diff --git a/output/posts/post-lists.html b/output/posts/post-lists.html new file mode 100644 index 0000000..5d1573e --- /dev/null +++ b/output/posts/post-lists.html @@ -0,0 +1,41 @@ + + + + + + + +Sitemap for project org-posts + + + + + +
+ +
Updated: 2025-08-06 Wed 22:49
+
+
+

Sitemap for project org-posts

+ +
+
+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
+
+ + diff --git a/output/posts/posts-intro.html b/output/posts/posts-intro.html new file mode 100644 index 0000000..5e708a2 --- /dev/null +++ b/output/posts/posts-intro.html @@ -0,0 +1,82 @@ + + + + + + + +Posts Introduction + + + + + + +
+ +
Updated: 2025-08-06 Wed 21:11
+
+
+

Posts Introduction

+
+

Introduction

+
+

+In this section you will find posts related to both technical and non-technical topics. As Einstein said: โ€œIf you canโ€™t explain it simply you donโ€™t understand it well enoughโ€, thus the goal with these posts is to develop the skill of being able to deliver habitual high quality explanations as well as reinforcing the topic learnt. +

+ +

+Generally, for teachers, this is done by taking the time to develop their own capacity to explain key concepts simply. In some institutions, departmental CPD is well spent rehearsing ways to improve the ability to explain the more difficult material in a more simpler way. +

+ +

+When we study a topic, we get a grasp of the thing we are trying to learn, and then later on one may realise that they didn't actually learn it. The context of this differs for every person, for some it may be in the field of medicine, others in the field of software development; we may find ourselves with a solution without knowing the why. +

+ +

+Explaining topics is a fantastic method of learning, an article written by Juha-Matti Santala titled Explaining it helps you learn it says: +

+ +
+

+The act of teaching (and more accurately, the act of preparing to teach) forces us to discover the knowledge gaps, fill them and improve our communication skills to a level where we know enough to confidently, comfortably and successfully transfer that knowledge from our mind to another mind. +

+
+ +

+The article further quotes Henrik Jernevad in whose blog post writes: +

+ +
+

+I think the magic comes when you need to put words to things. It is quite easy to have a vague picture of something in your mind without realizing how vague it actually is. Putting things in words exposes that vagueness. +

+
+ +

+The final line Putting things in words exposes that vagueness is profound in the context of learning. In the pursuit of any academic discipline, we're often confronted with vagueness. Yet, itโ€™s often through explaining a concept to someone else, using your own words, analogies, and diagrams, that one ends up actually understanding it. +

+ +

+<2025-08-06 Wed> +

+
+
+
+
+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
+
+ + diff --git a/output/posts/zettelkasten.html b/output/posts/zettelkasten.html new file mode 100644 index 0000000..86c5326 --- /dev/null +++ b/output/posts/zettelkasten.html @@ -0,0 +1,41 @@ + + + + + + + +Zettelkasten Method + + + + + + +
+ +
Updated: 2025-08-06 Wed 21:10
+
+
+

Zettelkasten Method

+

+Testing +

+
+
+
+ +
+Created with Emacs 30.1 (Org mode 9.7.11) on Debian GNU/Linux +
+
+
+ + diff --git a/output/script.js b/output/script.js new file mode 100644 index 0000000..e55bd2d --- /dev/null +++ b/output/script.js @@ -0,0 +1,21 @@ + +// COPY BUTTON: +document.addEventListener("DOMContentLoaded", function () { + document.querySelectorAll("pre.src").forEach(function (block) { + const button = document.createElement("button"); + button.innerText = "Copy"; + button.className = "copy-btn"; + + // Append button inside
+    block.appendChild(button);
+
+    button.addEventListener("click", function () {
+      const text = block.innerText.replace(button.innerText, ""); // exclude button text
+      navigator.clipboard.writeText(text.trim()).then(() => {
+        button.innerText = "Copied!";
+        setTimeout(() => (button.innerText = "Copy"), 1500);
+      });
+    });
+  });
+});
+
diff --git a/output/style.css b/output/style.css
index 115bc83..f49d1bd 100644
--- a/output/style.css
+++ b/output/style.css
@@ -6,53 +6,92 @@
   --code-bg: #f0f0f0;
 }
 
-body.dark {
-  --bg: #121212;
-  --fg: #e0e0e0;
-  --link: #8ab4f8;
-  --heading: #7baaf7;
-  --code-bg: #1e1e1e;
-}
 
 body {
-  font-family: sans-serif;
-  max-width: 700px;
-  margin: 2rem auto;
-  padding: 1rem;
-  line-height: 1.6;
   background-color: var(--bg);
   color: var(--fg);
   transition: background-color 0.3s, color 0.3s;
 }
 
+/* Headings (override org.css if needed) */
 h1, h2, h3 {
   color: var(--heading);
 }
 
+/* Links */
 a {
   color: var(--link);
-  text-decoration: none;
 }
-
 a:hover {
   text-decoration: underline;
 }
 
-pre, code {
-  background: var(--code-bg);
-  padding: 0.2em 0.4em;
+/* Copy button inside code blocks */
+.copy-btn {
+  position: absolute;
+  top: 0.4em;
+  right: 0.4em;
+  background-color: var(--code-bg);
+  color: var(--heading);
+  border: 1px solid var(--heading);
   border-radius: 4px;
-  font-family: monospace;
+  padding: 0.2em 0.6em;
+  font-size: 0.8rem;
+  cursor: pointer;
+  z-index: 10;
+  transition: background-color 0.3s;
 }
 
-/* Toggle button */
-#theme-toggle {
-  position: fixed;
-  top: 1rem;
-  right: 1rem;
-  padding: 0.4em 0.8em;
-  background: var(--code-bg);
-  border: none;
-  border-radius: 5px;
-  cursor: pointer;
+.copy-btn:hover {
+  background-color: var(--heading);
+  color: var(--code-bg);
+}
+
+/* Nav styling */
+nav {
+  border-radius: 6px;
+  margin-bottom: 1rem;
+  font-weight: 600;
+  font-size: 1.1rem;
+}
+
+nav a {
+  color: var(--link);
+  text-decoration: none;
+  font-weight: 600;
+}
+
+nav a:hover {
+  text-decoration: underline;
+}
+
+/* Footer styling */
+footer {
+  color: var(--fg);
+  padding: 1rem;
+  margin-top: 2rem;
+  border-radius: 6px;
+  text-align: center;
+  font-size: 0.9rem;
+  font-style: italic;
+  
+}
+#updated {
+  font-size: 0.8rem;
+  color: var(--fg);
+  margin-bottom: 1rem;
+  font-style: italic;
+}
+pre.src::before {
+  content: none !important;
+}
+/* Container: 
 */
+pre.src {
+    padding: 1.5em 1em 1em 1em; /* top padding leaves space for button */
+    font-family: "Fira Mono", "Courier New", monospace;
+    font-size: 0.9rem;
+    line-height: 1.4;
+    overflow-x: auto;
+    white-space: pre-wrap; /* wrap long lines */
+    
 }
diff --git a/output/theme-toggle.js b/output/theme-toggle.js
deleted file mode 100644
index 73632b1..0000000
--- a/output/theme-toggle.js
+++ /dev/null
@@ -1,35 +0,0 @@
-function setTheme(mode) {
-  if (mode === 'dark') {
-    document.body.classList.add('dark');
-    localStorage.setItem('theme', 'dark');
-  } else {
-    document.body.classList.remove('dark');
-    localStorage.setItem('theme', 'light');
-  }
-}
-
-function toggleTheme() {
-  const current = document.body.classList.contains('dark') ? 'dark' : 'light';
-  setTheme(current === 'dark' ? 'light' : 'dark');
-  console.log("Testing");
-}
-
-window.addEventListener('DOMContentLoaded', () => {
-  const saved = localStorage.getItem('theme');
-
-  // Auto-detect system preference if no saved preference
-  if (!saved) {
-    if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
-      setTheme('dark');
-    }
-  } else if (saved === 'dark') {
-    setTheme('dark');
-  }
-
-  // Add the toggle button
-  const button = document.createElement('button');
-  button.id = 'theme-toggle';
-  button.innerText = 'Toggle Theme';
-  button.onclick = toggleTheme;
-  document.body.appendChild(button);
-});