From 4f226efb2417a3395156749b75b8c5881b974c18 Mon Sep 17 00:00:00 2001 From: Snoweuph Date: Sat, 21 Dec 2024 00:55:00 +0100 Subject: [PATCH] Setup --- Readme.md | 8 ++++---- src/lib.js | 5 +++++ src/main.user.js | 9 +++++---- 3 files changed, 14 insertions(+), 8 deletions(-) create mode 100644 src/lib.js diff --git a/Readme.md b/Readme.md index cb8e951..425048c 100644 --- a/Readme.md +++ b/Readme.md @@ -1,11 +1,11 @@ -# $REPO_NAME +# ${REPO_NAME} -![Stars Badge]($REPO_HTTPS_URL/badges/stars.svg?style=flat-square&label=★Stars&labelColor=gray&color=yellow) -![QS Badge]($REPO_HTTPS_URL/actions/workflows/qs.yml/badge.svg?style=flat-square&label=Status&labelColor=gray) +![Stars Badge](${REPO_LINK}/badges/stars.svg?style=flat-square&label=★Stars&labelColor=gray&color=yellow) +![QS Badge](${REPO_LINK}/actions/workflows/qs.yml/badge.svg?style=flat-square&label=Status&labelColor=gray) ## Installation -[![Install Userscript](https://img.shields.io/badge/Install_Userscript-${REPO_NAME_SNAKE}-gray?style=for-the-badge&logo=greasyfork&logoColor=black&labelColor=brown)]($REPO_HTTPS/raw/branch/main/src/main.user.js) +[![Install Userscript](https://img.shields.io/badge/Install_Userscript-${REPO_NAME}-gray?style=for-the-badge&logo=greasyfork&logoColor=black&labelColor=brown)](${REPO_LINK}/raw/branch/main/src/main.user.js) ## Description diff --git a/src/lib.js b/src/lib.js new file mode 100644 index 0000000..ada0ad5 --- /dev/null +++ b/src/lib.js @@ -0,0 +1,5 @@ +function testLib() { + console.log('lib works!'); +} + +window.testLib = testLib; diff --git a/src/main.user.js b/src/main.user.js index 60dcd64..c0cb670 100644 --- a/src/main.user.js +++ b/src/main.user.js @@ -1,12 +1,13 @@ // ==UserScript== -// @name $REPO_NAME -// @namespace https://git.euph.dev/$REPO_OWNER +// @name ${REPO_NAME} +// @namespace https://git.euph.dev/${REPO_OWNER} // @match * -// @require https://git.euph.dev/Snoweuph/CCNA_Autofill_Userscript/raw/branch/main/src/fetch.js -// @require https://git.euph.dev/Snoweuph/CCNA_Autofill_Userscript/raw/branch/main/src/answer.js +// @require ${REPO_LINK}/raw/branch/main/src/lib.js // @grant GM_setValue // @grant GM_getValue // @grant GM_xmlhttpRequest // @version 0.0.1 // @author Userscripts // ==/UserScript== + +window.testLib();