forked from MyEtherWallet/ethereum-lists
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
7638551
commit 5440052
Showing
17 changed files
with
329 additions
and
287 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,35 @@ | ||
const fs = require('fs'); | ||
const whitelist = [ | ||
'.git', | ||
'.gitignore', | ||
'.prettierignore', | ||
'.prettierrc', | ||
'.travis.yml', | ||
'LICENSE', | ||
'README.md', | ||
'checkContract.js', | ||
'checkDirectory.js', | ||
'checkToken.js', | ||
'compile.js', | ||
'createFiles.js', | ||
'dist', | ||
'node_modules', | ||
'package-lock.json', | ||
'package.json', | ||
'recreateFiles.js', | ||
'renameToChecksum.js', | ||
'src', | ||
'validateObject.js' | ||
]; | ||
|
||
function checkDirectory() { | ||
const currentContent = fs.readdirSync('./'); | ||
whitelist.forEach((file, idx) => { | ||
if (currentContent[idx] !== file) { | ||
console.log(`Move ${currentContent[idx]} to proper folder or delete it.`); | ||
process.exit(1); | ||
} | ||
}); | ||
} | ||
|
||
module.exports = checkDirectory; |
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 |
---|---|---|
@@ -1,13 +1,23 @@ | ||
const recreateFiles = require('./recreateFiles'); | ||
const createFiles = require('./createFiles'); | ||
const checkContract = require('./checkContract'); | ||
const checkDirectory = require('./checkDirectory'); | ||
const checkToken = require('./checkToken'); | ||
const createFiles = require('./createFiles'); | ||
const recreateFiles = require('./recreateFiles'); | ||
const renameToChecksum = require('./renameToChecksum'); | ||
|
||
function compile() { | ||
recreateFiles(); | ||
checkDirectory(); | ||
console.log('Directory is clean!'); | ||
createFiles(); | ||
checkToken(); | ||
console.log('Created files!'); | ||
recreateFiles(); | ||
console.log('Recreated files!'); | ||
renameToChecksum(); | ||
console.log('Rename files to checksum!'); | ||
checkContract(); | ||
console.log('Contracts are fine!'); | ||
checkToken(); | ||
console.log('Tokens are fine!'); | ||
} | ||
|
||
compile(); |
Oops, something went wrong.