Compare commits

...
Sign in to create a new pull request.

27 commits

Author SHA1 Message Date
b756119aba git config
All checks were successful
default / build-and-deploy (push) Successful in 33s
2025-03-30 19:42:12 +03:00
4566d7ccbb fix
Some checks failed
default / build-and-deploy (push) Failing after 31s
2025-03-30 19:37:54 +03:00
33e3c7eedb commit via checkout action
Some checks failed
default / build-and-deploy (push) Failing after 0s
2025-03-30 19:35:55 +03:00
e90b212bb3 do not change username
Some checks failed
default / build-and-deploy (push) Failing after 30s
2025-03-30 19:34:27 +03:00
92165ca5ca simplify deploy
Some checks failed
default / build-and-deploy (push) Failing after 32s
2025-03-30 19:28:45 +03:00
15b098948c add pull.rebase
Some checks failed
default / build-and-deploy (push) Failing after 26s
2025-03-30 19:25:24 +03:00
0c611fb314 fix deploy
Some checks failed
default / build-and-deploy (push) Failing after 27s
2025-03-30 19:23:40 +03:00
c721632642 fix git key
Some checks failed
default / build-and-deploy (push) Failing after 29s
2025-03-30 19:14:32 +03:00
7d8ca6ad3d simplify build
Some checks failed
default / build-and-deploy (push) Failing after 29s
2025-03-30 19:13:02 +03:00
a59be15074 simplify build
Some checks failed
default / build-and-deploy (push) Failing after 35s
2025-03-30 19:11:02 +03:00
a293c5fc3b try to fix deploys
Some checks failed
default / build-and-deploy (push) Failing after 31s
2025-03-30 18:53:54 +03:00
3e565eacd6 remove unnecessary installs
Some checks failed
default / build-and-deploy (push) Failing after 29s
2025-03-30 18:50:19 +03:00
f318a6ed14 syntax fix
Some checks failed
default / build-and-deploy (push) Failing after 31s
2025-03-30 18:48:29 +03:00
027680de21 use container instead of alpine
Some checks failed
default / build-and-deploy (push) Failing after 0s
2025-03-30 18:47:22 +03:00
7f72fd3795 remove drone ci link
Some checks failed
default / build-and-deploy (push) Failing after 31s
2025-03-30 18:43:49 +03:00
b432e8665e update pipeline
All checks were successful
default / build-and-deploy (push) Successful in 33s
2025-03-30 16:31:11 +03:00
98676312a8 fix gitea url & fix build
Some checks failed
default / build-and-deploy (push) Failing after 41s
2025-03-30 16:27:27 +03:00
1c58672643 use actions
Some checks failed
default / build-and-deploy (push) Failing after 40s
2025-03-30 16:25:22 +03:00
71e7c08bd4 add gist link
All checks were successful
continuous-integration/drone/push Build is passing
2025-03-08 18:56:31 +03:00
1b6b0e20e8 fix for mirrors (I forgot another link)
Some checks reported errors
continuous-integration/drone/push Build was killed
2024-12-25 17:10:14 +03:00
4185e69b2d fix for mirrors
All checks were successful
continuous-integration/drone/push Build is passing
2024-12-25 17:07:23 +03:00
d8211b64d0 update proxy links
All checks were successful
continuous-integration/drone/push Build is passing
2024-08-29 13:17:40 +03:00
b881572e45 remove edit this page link
All checks were successful
continuous-integration/drone/push Build is passing
2023-11-15 18:13:24 +03:00
4c37409a54 custom scrollbar
All checks were successful
continuous-integration/drone/push Build is passing
2023-11-13 09:41:00 +03:00
e9e8af365a another fix for deploy
All checks were successful
continuous-integration/drone/push Build is passing
2023-11-12 23:56:17 +03:00
a9ab6667c2 fix for deploy
Some checks failed
continuous-integration/drone/push Build is failing
2023-11-12 23:53:12 +03:00
cbc7a01913 remove live.js support
Some checks failed
continuous-integration/drone/push Build is failing
2023-11-12 23:47:43 +03:00
8 changed files with 61 additions and 288 deletions

View file

@ -1,37 +0,0 @@
kind: pipeline
type: docker
name: default
steps:
- name: generate
image: golang:1.19-alpine
commands:
- apk add --no-cache curl make bash
- make all
- name: release
image: alpine:latest
environment:
SSH_KEY:
from_secret: ssh_key
commands:
- apk add --no-cache git openssh
- mkdir -p $HOME/.ssh
- echo "$SSH_KEY" > $HOME/.ssh/id_rsa
- ssh-keyscan -H git.neur0tx.site > $HOME/.ssh/known_hosts 2> /dev/null
- chmod -R 600 $HOME/.ssh
- cd .pub
- git clone --filter=tree:0 git@git.neur0tx.site:Neur0toxine/neur0tx.site.git
- cd neur0tx.site
- git checkout gitea-pages || git checkout -b gitea-pages
- cd ..
- mv neur0tx.site/.git .
- rm -rf neur0tx.site
- git add .
- git commit -a -m "`date +'%Y-%m-%d %R:%S'` > deploy"
- git push -u origin gitea-pages
- cd ..
- rm -rf .pub
trigger:
branch:
- master

View file

@ -0,0 +1,37 @@
name: default
on:
push:
branches:
- master
jobs:
build-and-deploy:
runs-on: docker
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Generate
uses: docker://golang:1.23-alpine
with:
entrypoint: /bin/sh
args: -c "apk add --no-cache curl make bash && make all"
- name: Prepare the build
run: mv .pub /tmp/build
- name: Checkout gitea-pages reference
uses: actions/checkout@v4
with:
ref: gitea-pages
- name: Publish
run: |
git config user.name "${{ env.GITHUB_ACTOR }}"
git config user.email "${{ secrets.EMAIL }}"
mv .git /tmp/build/
cd /tmp/build
git add .
git commit -a -m "`date +'%Y-%m-%d %R:%S'` > deploy"
git push -u origin gitea-pages

View file

@ -1,7 +0,0 @@
#!/bin/sh
GITEA_BASE_URL="https://gitea.neur0tx.site/Neur0toxine/neur0tx.site/_edit/master"
url="${GITEA_BASE_URL}/${ZS_FILE}"
printf "<a href=\"%s\" rel=\"nofollow\" target=\"_blank\">✍️ Edit this page on Gitea.</a>" "$url"

View file

@ -17,10 +17,9 @@
<body>
<nav>
<a id="brand" href="/">home 🏠</a>
<a href="https://proxy.neur0tx.site">proxy 💻</a>
<a href="/proxy.html">proxy 💻</a>
</nav>
<article>{{ content }}</article>
{{ editthispage }}
<footer>
Copyright &copy; Neur0toxine ·
Last modified <time datetime="{{ date +%Y-%m-%dT%H:%M:%SZ%:z }}">{{ date }}</time> ·

View file

@ -4,11 +4,6 @@ set -e
JS="highlight umbrella"
# Load live.js for non-production builds for faster development
if [ -z "$ZS_PRODUCTION" ]; then
JS="$JS live"
fi
for js in $JS; do
printf "<script type=\"application/javascript\" src=\"/assets/js/%s.js\"></script>\n" "$js"
done

View file

@ -23,4 +23,23 @@ body {
body nav:first-of-type {
padding: 0 calc((100vw - 60rem)/2);
}
}
/* Custom scrollbar */
::-webkit-scrollbar {
width: 8px;
height: 8px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: var(--button-hover);
}
::-webkit-scrollbar-thumb:hover {
background: #384e62;
}

View file

@ -1,233 +0,0 @@
/*
Live.js - One script closer to Designing in the Browser
Written for Handcraft.com by Martin Kool (@mrtnkl).
Version 4.
Recent change: Made stylesheet and mimetype checks case insensitive.
http://livejs.com
http://livejs.com/license (MIT)
@livejs
Include live.js#css to monitor css changes only.
Include live.js#js to monitor js changes only.
Include live.js#html to monitor html changes only.
Mix and match to monitor a preferred combination such as live.js#html,css
By default, just include live.js to monitor all css, js and html changes.
Live.js can also be loaded as a bookmarklet. It is best to only use it for CSS then,
as a page reload due to a change in html or css would not re-include the bookmarklet.
To monitor CSS and be notified that it has loaded, include it as: live.js#css,notify
*/
(function () {
var headers = { "Etag": 1, "Last-Modified": 1, "Content-Length": 1, "Content-Type": 1 },
resources = {},
pendingRequests = {},
currentLinkElements = {},
oldLinkElements = {},
interval = 1000,
loaded = false,
active = { "html": 1, "css": 1, "js": 1 };
var Live = {
// performs a cycle per interval
heartbeat: function () {
if (document.body) {
// make sure all resources are loaded on first activation
if (!loaded) Live.loadresources();
Live.checkForChanges();
}
setTimeout(Live.heartbeat, interval);
},
// loads all local css and js resources upon first activation
loadresources: function () {
// helper method to assert if a given url is local
function isLocal(url) {
var loc = document.location,
reg = new RegExp("^\\.|^\/(?!\/)|^[\\w]((?!://).)*$|" + loc.protocol + "//" + loc.host);
return url.match(reg);
}
// gather all resources
var scripts = document.getElementsByTagName("script"),
links = document.getElementsByTagName("link"),
uris = [];
// track local js urls
for (var i = 0; i < scripts.length; i++) {
var script = scripts[i], src = script.getAttribute("src");
if (src && isLocal(src))
uris.push(src);
if (src && src.match(/\blive.js#/)) {
for (var type in active)
active[type] = src.match("[#,|]" + type) != null
if (src.match("notify"))
alert("Live.js is loaded.");
}
}
if (!active.js) uris = [];
if (active.html) uris.push(document.location.href);
// track local css urls
for (var i = 0; i < links.length && active.css; i++) {
var link = links[i], rel = link.getAttribute("rel"), href = link.getAttribute("href", 2);
if (href && rel && rel.match(new RegExp("stylesheet", "i")) && isLocal(href)) {
uris.push(href);
currentLinkElements[href] = link;
}
}
// initialize the resources info
for (var i = 0; i < uris.length; i++) {
var url = uris[i];
Live.getHead(url, function (url, info) {
resources[url] = info;
});
}
// add rule for morphing between old and new css files
var head = document.getElementsByTagName("head")[0],
style = document.createElement("style"),
rule = "transition: all .3s ease-out;"
css = [".livejs-loading * { ", rule, " -webkit-", rule, "-moz-", rule, "-o-", rule, "}"].join('');
style.setAttribute("type", "text/css");
head.appendChild(style);
style.styleSheet ? style.styleSheet.cssText = css : style.appendChild(document.createTextNode(css));
// yep
loaded = true;
},
// check all tracking resources for changes
checkForChanges: function () {
for (var url in resources) {
if (pendingRequests[url])
continue;
Live.getHead(url, function (url, newInfo) {
var oldInfo = resources[url],
hasChanged = false;
resources[url] = newInfo;
for (var header in oldInfo) {
// do verification based on the header type
var oldValue = oldInfo[header],
newValue = newInfo[header],
contentType = newInfo["Content-Type"];
switch (header.toLowerCase()) {
case "etag":
if (!newValue) break;
// fall through to default
default:
hasChanged = oldValue != newValue;
break;
}
// if changed, act
if (hasChanged) {
Live.refreshResource(url, contentType);
break;
}
}
});
}
},
// act upon a changed url of certain content type
refreshResource: function (url, type) {
switch (type.toLowerCase()) {
// css files can be reloaded dynamically by replacing the link element
case "text/css":
var link = currentLinkElements[url],
html = document.body.parentNode,
head = link.parentNode,
next = link.nextSibling,
newLink = document.createElement("link");
html.className = html.className.replace(/\s*livejs\-loading/gi, '') + ' livejs-loading';
newLink.setAttribute("type", "text/css");
newLink.setAttribute("rel", "stylesheet");
newLink.setAttribute("href", url + "?now=" + new Date() * 1);
next ? head.insertBefore(newLink, next) : head.appendChild(newLink);
currentLinkElements[url] = newLink;
oldLinkElements[url] = link;
// schedule removal of the old link
Live.removeoldLinkElements();
break;
// check if an html resource is our current url, then reload
case "text/html":
if (url != document.location.href)
return;
// local javascript changes cause a reload as well
case "text/javascript":
case "application/javascript":
case "application/x-javascript":
document.location.reload();
}
},
// removes the old stylesheet rules only once the new one has finished loading
removeoldLinkElements: function () {
var pending = 0;
for (var url in oldLinkElements) {
// if this sheet has any cssRules, delete the old link
try {
var link = currentLinkElements[url],
oldLink = oldLinkElements[url],
html = document.body.parentNode,
sheet = link.sheet || link.styleSheet,
rules = sheet.rules || sheet.cssRules;
if (rules.length >= 0) {
oldLink.parentNode.removeChild(oldLink);
delete oldLinkElements[url];
setTimeout(function () {
html.className = html.className.replace(/\s*livejs\-loading/gi, '');
}, 100);
}
} catch (e) {
pending++;
}
if (pending) setTimeout(Live.removeoldLinkElements, 50);
}
},
// performs a HEAD request and passes the header info to the given callback
getHead: function (url, callback) {
pendingRequests[url] = true;
var xhr = window.XMLHttpRequest ? new XMLHttpRequest() : new ActiveXObject("Microsoft.XmlHttp");
xhr.open("HEAD", url, true);
xhr.onreadystatechange = function () {
delete pendingRequests[url];
if (xhr.readyState == 4 && xhr.status != 304) {
xhr.getAllResponseHeaders();
var info = {};
for (var h in headers) {
var value = xhr.getResponseHeader(h);
// adjust the simple Etag variant to match on its significant part
if (h.toLowerCase() == "etag" && value) value = value.replace(/^W\//, '');
if (h.toLowerCase() == "content-type" && value) value = value.replace(/^(.*?);.*?$/i, "$1");
info[h] = value;
}
callback(url, info);
}
}
xhr.send();
}
};
// start listening
if (document.location.protocol != "file:") {
if (!window.liveJsLoaded)
Live.heartbeat();
window.liveJsLoaded = true;
}
else if (window.console)
console.log("Live.js doesn't support the file protocol. It needs http.");
})();

View file

@ -1,5 +1,5 @@
# Links
- [gitea](https://gitea.neur0tx.site)
- [drone CI](https://drone.neur0tx.site)
- [proxy](https://proxy.neur0tx.site)
- [gitea](https://git.neur0tx.site)
- [gist](https://gist.neur0tx.site)
- [proxy](/proxy.html)