mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-09-10 22:54:45 +08:00
[dev] Fix path for tmp dir in daily script
This commit is contained in:
parent
27355c91eb
commit
f1572f4bfc
1 changed files with 2 additions and 1 deletions
|
@ -1,5 +1,6 @@
|
|||
#!/usr/bin/env babel-node
|
||||
const childProcess = require('child_process')
|
||||
const path = require('path')
|
||||
const mkdirp = require('mkdirp')
|
||||
const semver = require('semver')
|
||||
const program = require('commander')
|
||||
|
@ -40,7 +41,7 @@ function git(subCmd, opts = {}) {
|
|||
}
|
||||
|
||||
async function prependToFile(filepath, string) {
|
||||
mkdirp.sync('./tmp')
|
||||
mkdirp.sync(path.join(__dirname, '..', 'tmp'))
|
||||
await exec(`echo "${string}" > ./tmp/tmpfile`)
|
||||
await exec(`cat ${filepath} >> ./tmp/tmpfile`)
|
||||
await exec(`mv ./tmp/tmpfile ${filepath}`)
|
||||
|
|
Loading…
Add table
Reference in a new issue