mirror of
https://github.com/atom/atom.git
synced 2026-01-25 14:59:03 -05:00
Copy static/, dot-atom/ and vendor/ as they are
This commit is contained in:
@@ -5,7 +5,9 @@
|
||||
const cleanOutputDirectory = require('./lib/clean-output-directory')
|
||||
const transpileBabelPaths = require('./lib/transpile-babel-paths')
|
||||
const transpileCoffeeScriptPaths = require('./lib/transpile-coffee-script-paths')
|
||||
const copyStaticAssets = require('./lib/copy-static-assets')
|
||||
|
||||
cleanOutputDirectory()
|
||||
transpileBabelPaths()
|
||||
transpileCoffeeScriptPaths()
|
||||
copyStaticAssets()
|
||||
|
||||
22
build/lib/copy-static-assets.js
Normal file
22
build/lib/copy-static-assets.js
Normal file
@@ -0,0 +1,22 @@
|
||||
// This module exports a function that copies all the static assets into the
|
||||
// appropriate location in the build output directory.
|
||||
|
||||
'use strict'
|
||||
|
||||
const path = require('path')
|
||||
const fs = require('fs-extra')
|
||||
const computeDestinationPath = require('./compute-destination-path')
|
||||
const CONFIG = require('../config')
|
||||
|
||||
module.exports = function () {
|
||||
console.log('Copying static assets...');
|
||||
const sourcePaths = [
|
||||
path.join(CONFIG.repositoryRootPath, 'static'),
|
||||
path.join(CONFIG.repositoryRootPath, 'dot-atom'),
|
||||
path.join(CONFIG.repositoryRootPath, 'vendor')
|
||||
]
|
||||
|
||||
for (let srcPath of sourcePaths) {
|
||||
fs.copySync(srcPath, computeDestinationPath(srcPath))
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user