🏗️ Ensure cache is busted
This commit is contained in:
parent
b8984694e3
commit
0508fa7b0e
2 changed files with 6 additions and 1 deletions
|
|
@ -2,12 +2,17 @@ const { parse } = require('@ltd/j-toml');
|
|||
const { render } = require('mustache');
|
||||
const { readFile, writeFile } = require('node:fs/promises');
|
||||
const { resolve } = require('node:path');
|
||||
const util = require('node:util');
|
||||
const exec = util.promisify(require('node:child_process').exec);
|
||||
|
||||
async function compile() {
|
||||
const { stdout, stderr } = await exec('git rev-parse --short @');
|
||||
|
||||
const confPath = resolve('./config.toml');
|
||||
const confToml = await readFile(confPath, { encoding: 'utf8' });
|
||||
const config = parse(confToml);
|
||||
|
||||
config.version = stdout.trim();
|
||||
config.text = function () {
|
||||
const string = this.icon;
|
||||
return string.charAt(0).toUpperCase() + string.slice(1);
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<title>{{title}}</title>
|
||||
<link rel="stylesheet" href="https://maxst.icons8.com/vue-static/landings/line-awesome/line-awesome/1.3.0/css/line-awesome.min.css"/>
|
||||
<link rel="stylesheet" href="style.css"/>
|
||||
<link rel="stylesheet" href="style.css?ver={{version}}"/>
|
||||
</head>
|
||||
<body>
|
||||
<header class="py-3 mb-4 border-bottom">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue