-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from max-dev001/max
add dep code
- Loading branch information
Showing
3 changed files
with
31 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/* eslint-disable no-console */ | ||
const execa = require("execa"); | ||
const fs = require("fs"); | ||
(async () => { | ||
try { | ||
await execa("git", ["checkout", "--orphan", "gh-pages"]); | ||
// eslint-disable-next-line no-console | ||
console.log("Building started..."); | ||
await execa("npm", ["run", "build"]); | ||
// Understand if it's dist or build folder | ||
const folderName = fs.existsSync("dist") ? "dist" : "build"; | ||
await execa("git", ["--work-tree", folderName, "add", "--all"]); | ||
await execa("git", ["--work-tree", folderName, "commit", "-m", "gh-pages"]); | ||
console.log("Pushing to gh-pages..."); | ||
await execa("git", ["push", "origin", "HEAD:gh-pages", "--force"]); | ||
await execa("rm", ["-r", folderName]); | ||
await execa("git", ["checkout", "-f", "main"]); | ||
await execa("git", ["branch", "-D", "gh-pages"]); | ||
console.log("Successfully deployed, check your settings"); | ||
} catch (e) { | ||
// eslint-disable-next-line no-console | ||
console.log(e.message); | ||
process.exit(1); | ||
} | ||
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
const { defineConfig } = require('@vue/cli-service') | ||
module.exports = defineConfig({ | ||
transpileDependencies: true, | ||
lintOnSave: false | ||
lintOnSave: false, | ||
publicPath:'events-app' | ||
}) |