Compare commits
3
Commits
dist
..
b05ef16265
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b05ef16265 | ||
|
|
6ff0b5c96c | ||
|
|
86f7fdcb30 |
No files matched your search
@@ -0,0 +1,41 @@
|
||||
name: Publish userscripts
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
paths:
|
||||
- 'src/**'
|
||||
- '.gitea/workflows/**'
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Build dist
|
||||
run: |
|
||||
VERSION=$(TZ=AEST-10 date +%Y.%m.%d.%H%M)
|
||||
BASE=https://code.home-brightview.com/matt.rb/dynamics-userscripts/raw/branch/dist
|
||||
mkdir -p dist
|
||||
for f in src/*.user.js; do
|
||||
n=$(basename "$f" .user.js)
|
||||
sed -e "s|^// @version .*|// @version $VERSION|" \
|
||||
-e "s|^// ==/UserScript==|// @updateURL $BASE/$n.meta.js\n// @downloadURL $BASE/$n.user.js\n// ==/UserScript==|" \
|
||||
"$f" > "dist/$n.user.js"
|
||||
sed -n '1,/==\/UserScript==/p' "dist/$n.user.js" > "dist/$n.meta.js"
|
||||
echo "Built $n $VERSION"
|
||||
done
|
||||
echo "VERSION=$VERSION" >> "$GITHUB_ENV"
|
||||
|
||||
- name: Force-push dist branch
|
||||
env:
|
||||
TOKEN: ${{ secrets.PUBLISH_TOKEN }}
|
||||
run: |
|
||||
cd dist
|
||||
git init -b dist
|
||||
git config user.name "gitea-actions"
|
||||
git config user.email "actions@home-brightview.com"
|
||||
git add .
|
||||
git commit -m "Publish $VERSION"
|
||||
git push -f "https://matt.rb:${TOKEN}@git.home-brightview.com/${{ github.repository }}.git" dist
|
||||
@@ -0,0 +1,3 @@
|
||||
# dynamics-userscripts
|
||||
|
||||
Microsoft Dynamics 365 CRM user enhancement scripts
|
||||
@@ -1,12 +0,0 @@
|
||||
// ==UserScript==
|
||||
// @name CRM User Enhancements
|
||||
// @namespace https://git.home-brightview.com/matt.rb
|
||||
// @version 2026.10.25.1520
|
||||
// @author matt.rb
|
||||
// @match https://*.dynamics.com/*
|
||||
// @run-at document-idle
|
||||
// @grant none
|
||||
// @noframes
|
||||
// @updateURL https://code.home-brightview.com/matt.rb/dynamics-userscripts/raw/branch/dist/non-compliant-alert.meta.js
|
||||
// @downloadURL https://code.home-brightview.com/matt.rb/dynamics-userscripts/raw/branch/dist/non-compliant-alert.user.js
|
||||
// ==/UserScript==
|
||||
@@ -1,14 +1,12 @@
|
||||
// ==UserScript==
|
||||
// @name CRM User Enhancements
|
||||
// @namespace https://git.home-brightview.com/matt.rb
|
||||
// @version 2026.10.25.1520
|
||||
// @version 1.0.0
|
||||
// @author matt.rb
|
||||
// @match https://*.dynamics.com/*
|
||||
// @run-at document-idle
|
||||
// @grant none
|
||||
// @noframes
|
||||
// @updateURL https://code.home-brightview.com/matt.rb/dynamics-userscripts/raw/branch/dist/non-compliant-alert.meta.js
|
||||
// @downloadURL https://code.home-brightview.com/matt.rb/dynamics-userscripts/raw/branch/dist/non-compliant-alert.user.js
|
||||
// ==/UserScript==
|
||||
|
||||
// Data comes from the Dataverse Web API with the signed-in user's own session,
|
||||
Reference in new issue
Block a user