new Vue({ el: '#app', data: { name: 'TUSH', flavor: '', path: '', command: '', peersList: [ ], optionz2z: 1, optionServer: 1, optionTor: 0, optionGen: 0, optionGenProcLimit: 2, optionEquihashSolver: 'tromp', optionAllowList: [], tempAllowlist: '', customPath: 0, customMinerToAddress: 0, optionName: 'TUSH', optionAlgo: ' -ac_algo=randomx ', optionPubkey: '', optionReward: '1250000000', // in puposhis optionz2z: 1, optionSupply: '21000000', optionBlocktime: 60, optionHalving: 210000, optionRpcAllowIp: '127.0.0.1', optionRpcUser: 'rpcuser', optionRpcPassword: Math.random().toString(36).slice(2), optionTestNode: 0, optionShowMetrics: 0, optionDataDir: '', optionZIndex: 0, optionAddrIndex: 0, optionSpentIndex: 0, optionTimestampIndex: 0 }, methods: { setFlavor: function (option) { this.flavor = option if (this.flavor == 'Linux') { this.path = '/home/user/.hush/HUSH3.conf' } else if (this.flavor == "Mac OS") { this.path = '~/Library/Application Support/Hush/HUSH3.conf' } else { this.path = 'C:\\Users\\your_username\\AppData\\Roaming\\Hush\\HUSH3.conf' } $('.flavor-banner').show() $(document.body).animate({ 'scrollTop': $('#build').offset().top }, 1200); }, showPathInput: function () { $('#paths').toggle() }, pickPath: function () { }, showMinerInfo: function () { $('#threads').toggle() $('#minerAddress').toggle() if (this.customMinerToAddress == 1) { $('#minerInput').toggle() } }, showMinerAddress: function () { $('#minerInput').toggle() }, decreaseThreads: function () { if (this.optionGenProcLimit != 0) { this.optionGenProcLimit-- } }, increaseThreads: function () { this.optionGenProcLimit++ }, addAllowList: function (value) { this.optionAllowList.push(value) this.tempAllowlist = '' }, removeAllowListItem: function (item) { console.log(item) var index = this.optionAllowList.indexOf(item) this.optionAllowList.splice(index, 1) }, compile: function () { var currentdate = new Date(); var compileTime = currentdate.getDate() + "/" + (currentdate.getMonth()+1) + "/" + currentdate.getFullYear() + " @ " + currentdate.getHours() + ":" + currentdate.getMinutes() + ":" + currentdate.getSeconds() this.command = "git clone https://git.hush.is/hush/hush3
cd hush3
./build.sh
cd src
./hush-smart-chain -ac_name=" + this.optionName + this.optionAlgo + " -ac_supply=" + this.optionSupply + " -ac_blocktime=" + this.optionBlocktime + " -ac_private=" + this.optionz2z; this.command += " -ac_reward=" + this.optionReward + " -ac_halving=" + this.optionHalving; if(this.optionPubkey != '') this.command += " -ac_pubkey=" + this.optionPubkey; if(this.optionTestNode) this.command += " -testnode=1"; if(this.optionGen) this.command += " -gen=1"; /* if (this.optionAllowList.length != 0) { this.command = this.conf + "

whitelist=" + this.optionAllowList } for (var i = 0; i< this.peersList.length; i++) { if (i == 0) { this.command = this.conf + "
" } this.command = this.conf + "
addnode=" + this.peersList[i] } */ $('#profile').show() $('#clapping').show(); } } });