Title: PowerShell and Bitcoin Core Post by: vh on June 20, 2017, 02:45:00 AM Just sharing a few PowerShell commands that I recently worked out which may come in handy when working with your wallet in windows.
This requires PowerShell 5.0 for access to ConvertFrom-Json. Code: set-alias bitcoin-cli "C:\Program Files\Bitcoin\daemon\bitcoin-cli.exe" *as needed Code: #unlock for 60 seconds Title: Re: PowerShell and Bitcoin Core Post by: Inkhardy on December 18, 2017, 03:34:31 AM Thanks, I was trying to learn learn it udemy (https://www.udemy.com/user/mike-rodger/) but it's very hard to grasp.
Title: Re: PowerShell and Bitcoin Core Post by: immakingacoin on January 29, 2018, 11:00:50 PM If you are in Windows 7-10, open "My Documents" and the same way you would type in like "www.facebook.com" or something on an internet browser, go to the My Documents address bar and type "Powershell". And it will open a Windows Command line.
This link has a thing that you can Copy and Paste into the Command line (called a Script) that creates a Calculator that you can use. If you put in various things you can make apps that do different things. https://gallery.technet.microsoft.com/scriptcenter/7e08cb64-f621-44b2-810b-dab3827755ce Here are some older posts about Bitcoin and Powershell. Hello All, I am a hobbyist .Net developer and had been trying (unsuccessfully) to use the "Bitnet" project (http://sourceforge.net/projects/bitnet/ (http://sourceforge.net/projects/bitnet/)) for a while. I finally got fed up and decided to start from scratch, below you will find the "first-pass"/"proof of concept" implementation of some of the "more commonly" used bitcoind rpc calls. Most of the work is in the string formatting, and you will still have to handle the json string that gets returned, but its a start, and hopefully someone will find it useful. It makes use of Invoke-WebRequest command available in Powershell 4.0 Any input would be appreciated! Feel free to use/distribute to your hearts content, I simply ask that any improvements or extensions make their way back to this thread. Enjoy: copy the following text into a new file and save it as PowerCoin.ps1 H07ZmHjToR9k3L6+FtInvboy3TQktffyrVKph2hRnhHmZwOu1zomf9kgVBThEaCLbo0Kb5VfSpesiTvmsCnNBiE= (Signed with my Tip Address) Code: ##Title: PowerCoin Hey Guy, i wrote a script to monitor my mining rig by netcat latest log to Seashell because i am too tired to watch every via Teamviewer. This is also script for auto relaunch Mining ClayMore. It may work with other Miner like ccminer, but i havent tested yet, so feel free to try. All script i wrote is batch, powershell and bash. Everything is clear code. You can check on your own. Requirement: - Powershell - Windows 10 with SubSystem Linux included. ( You can try cygwin) Why: - Batch is good, but it is limited. Powershell can reach System Process Level Monitor. - Windows Pipe is stupid. Command must finish before pipe to other. Linux is line by line pipe. Step by Step Guide: 1. Install SubSystem Linux by following online guide: https://msdn.microsoft.com/en-us/commandline/wsl/install-win10 TLD'R: - Run in Powershell: Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux - Enable Developer Mode: https://www.ghacks.net/2015/06/13/how-to-enable-developer-mode-in-windows-10-to-sideload-apps/ - Run cmd and type "bash" (without quotes) 2. Copy all to your claymore directory. Make sure start-eth-edited.bat is same directory with file *Miner.exe 3. Edit file auto.txt. Change your email, Bot_email ,your *Miner.exe and Worker value. ( I use Gmail so if you use anything else, please edit mail config yourself) 4. Create shortcut start-eth-edited.bat to Startup Directory to run with Windows startup. !!!! Windows file like .txt and .bat is free to edit. but .BASH (or any thing run inside BASH) must be edited by vim inside bash. If you edit .bash file inside windows, please contact me to fix. Linux file cant contain /r charater. After success, you will receive mail like this. It contains link of seashells.io link. http://prntscr.com/hii7re Seashells.io will monitor your rig like this. http://prntscr.com/hii8ay Flow: Start-eth-edited ---Loop---> auto.bat auto.txt --variable--> auto.bat auto.bat --call--> script/FindProcessMining.ps1 ; find top 15 process with Highest CPU auto.bat --excute--> MiningProcess ; excute Mining Process if top process doesnt have Mining Process auto.bat --call --> script/seashell-mail.bash ; Setup seashell and send to your email. After that, script seashell sleep forever to prevent bash close. If you need any support or have any feed back, comment or email me: sangvohoang@vnoss.org TODO Next: - Fix all remain bug. - Move from Mail to Messenger Facebook Bot. I am writing a Bot on Facebook Messenger but I dont have enough money to buy a vps contain data. - Messenger Bot will have lot lot more feature than this. Include manage your own rigs on Messenger. !!! Script is Free to use. But i need your help to improve the script. Please donate me at ETH Address: 0x0A7721Bef04B491F07cCd02102622E1CdcD84a76 Link: https://drive.google.com/file/d/14pGlf_1Cy-Ilhy4zLrH5Gk0IdICIMtGK/view?usp=sharing It really is a pain to identify which GPU needs attention based on information available in Windows. The closest I have come to identifying a GPU index to its PCI slot is demonstrated in the below Powershell script. But even then, each Windows install is different so this procedure can't really be reproduced. I am posting this in case someone has come across a better method or can expand on this script. The idea behind this script is to identify all PCI devices and their children in Windows. Then, one has to unplug GPU by GPU and correlate the PCI device to a physical PCI slot. Once you have this cross reference, you can disable the GPUs you need in order to identify them. The disabled GPUs will output a ProblemCode other than zero in the script. Required DeviceManagement Cmdlets: https://gallery.technet.microsoft.com/Device-Management-7fad2388 (https://gallery.technet.microsoft.com/Device-Management-7fad2388) Powershell Script: https://pastebin.com/x3zzzgru (https://pastebin.com/x3zzzgru) Powershell Output: https://i.imgur.com/S4KtFAB.png /c Title: Re: PowerShell and Bitcoin Core Post by: immakingacoin on January 29, 2018, 11:10:15 PM Powershell Cmdlets
https://technet.microsoft.com/en-us/library/ff714569.aspx Powershell Cookbook http://www.reedbushey.com/86Windows%20Powershell%20Cookbook%203rd%20Edition.pdf Powershell Videos https://www.youtube.com/watch?v=wQOONLaozjQ&list=PL8U9xbzeyGGbV8pqFuMK9WZn69IyinIMF Title: Re: PowerShell and Bitcoin Core Post by: immakingacoin on January 29, 2018, 11:14:11 PM PowerShell
https://github.com/clymb3r/PowerShell https://github.com/SublimeText/PowerShell https://github.com/RamblingCookieMonster/PowerShell https://github.com/lazywinadmin/PowerShell https://github.com/Azure/azure-powershell https://github.com/Jackbennett/powershell https://github.com/obscuresec/PowerShell https://github.com/PyroTek3/PowerShell-AD-Recon https://github.com/mattifestation/PowerShellArsenal https://github.com/PowerShellMafia/PowerSploit https://github.com/dahlbyk/posh-git https://github.com/dfinke/powershell-for-developers https://github.com/alexinslc/powershell https://github.com/nullbind/Powershellery https://github.com/PlagueHO/Powershell https://github.com/dfinke/powershell https://github.com/hsmalley/Powershell https://github.com/stefanstranger/PowerShell https://github.com/uxone/powershell https://github.com/varonis/powershell https://github.com/lgulliver/Powershell https://github.com/vMotioned/PowerShell https://github.com/zloeber/Powershell https://github.com/OfficeDev/PnP-PowerShell https://github.com/bpatra/powershell https://github.com/pester/Pester https://github.com/kmarquette/Powershell https://github.com/PowerShell/PowerShell-Docs https://github.com/BenjaminArmstrong/Hyper-V-PowerShell https://github.com/splunk/splunk-reskit-powershell https://github.com/MrPowerScripts/PowerScripts https://github.com/petrsnd/Powershell https://github.com/subTee/PoshRat https://github.com/davehull/Kansa https://github.com/CosmosKey/PSIS https://github.com/besimorhino/powercat https://github.com/janikvonrotz/PowerShell-PowerUp https://github.com/SitecorePowerShell/Console https://github.com/guitarrapc/PowerShellUtil https://github.com/andrebocchini/sccm-powershell-automation-module https://github.com/jenkinsci/powershell-plugin https://github.com/cdhunt/WindowsAudioDevice-Powershell-Cmdlet https://github.com/abswaxing/PowerShell https://github.com/dotCipher/CoinBot https://github.com/PProvost/vim-ps1 Title: Re: PowerShell and Bitcoin Core Post by: immakingacoin on January 29, 2018, 11:21:08 PM Microsoft Script Resources
https://gallery.technet.microsoft.com/scriptcenter Title: Re: PowerShell and Bitcoin Core Post by: 13stmfpa on January 31, 2018, 02:52:00 AM holy cow!!! you should working for MSFT - Great work!
Title: Re: PowerShell and Bitcoin Core Post by: btctousd81 on January 31, 2018, 12:17:31 PM sorry for stupid question, but what does it do ?
i am new to powershell. Thanks |