How To Tweet From CLI On Windows 10 w. Node.js

Always working from PowerShell, CMD, Git Bash, or Git Shell? Ever want to tweet from the command line while your pushing code to your Github repository? I was interested in doing this on my laptop, making it easy to tweet on the go while I’m coding away at a coffee shop. I’d like keep my phone face down or in my pocket to avoid distractions… But that urge to tweet happens to often. Windows Store Twitter app is crap, and Twitter.com in browser is always sluggish… Let’s just tweet from the command line!

Tweet from CLI with Node.js

1.) Download & Install Node.js

2.) Run cmd.exe or PowerShell. I prefer to use Git Bash.

3.) Install cli-tweet by typing this command in:

npm install cli-tweet -g

4.) Now we need to see where npm installed the npm_modules folder.
npm root
It will return a path that we need.


5.) Open File Explorer, Right Click “This PC” -> Properties, click Advanced system settings, then click Environment Variables. Copy and paste the path that npm root gave you into your Windows 10 Systems PATH.

6.) Close your CLI window and run it again in Administrative Mode.

7.) Type the following:
tweet config

8.) It will give you an authorization URL that you have to copy and paste into your browser. Once the page loads, login and authorize RaedsLab app and it will give you a token to enter.

9.) With cli-tweet configured, try typing

echo "Hello Universe" | tweet

Do you like this awesome cli tweet tool? Go star the repo over on Github! If you don’t want to use RaedsLab Twitter app, you can create your own Twitter app and clone cli-tweet repository. In main.js line 13-14 you should see the key and secret for your Twitter App. You can install cli-tweet with your own key with the command: npm install /path

TP-LINK TL-WN725N on BAMT 1.5

LitecoinMiner-5

I recently was asked to take a look at a Litecoin miner logs due to stability issues, I had no idea how deep this rabbit hole would go. After many struggles with Xubuntu and AMD drivers, I found BAMT. BAMT aka “Big Ass Miner Thing” is a fork of the original BAMT project that was aborted, picked up by Bee on litecointalk.org – I’ve since rebuilt a miner and built 2 personal litecoin mining rigs. If you are in Bellingham, Whatcom, Skagit, Snohomish, or Vancouver Lower Mainland and need technical assistance with Bitcoin / Litecoin miners, feel free to reach out. I do it for the Dogecoin!

Repository can be found here:
https://bitbucket.org/beebee/bamt/

Download BAMT from Bee’s maintained thread:
https://litecointalk.org/index.php?topic=2924.0

How To Get TP-LINK TL-WN725N on BAMT 1.5

I wanted to use a USB Wifi dongle on BAMT for my dogecoin mining rigs so that I can relocate them into my garage. I randomly ordered a cheap $9 Wifi USB dongle on Amazon and figured making the leap of faith would be fun. Here’s how I got it running on BAMT.

I referenced WikiDevi.com for the appropriate repository to clone. I had the v2 of this Nano USB.

https://wikidevi.com/wiki/TP-LINK_TL-WN725N_v2

The repository is in the sidebar, I laughed audibly when I figured out BAMT has git natively, thank you Bee or whoever put that there! If you’re version of BAMT doesn’t have git, in Root Terminal type: apt-get install git

If you’ve never compiled from source before, open up Root Terminal:

cd ~/
git clone https://github.com/lwfinger/rtl8188eu.git
cd rtl8188eu
make
sudo make install

These steps may vary, make sure you’re using the correct repository. If you’re not using a TP-LINK Google around or look around WikiDevi.com for your hardware.

I got frustrated when passphrase didn’t save. Posted to /r/bamt – after a bit I made an edit:

http://www.reddit.com/r/BAMT/comments/1zlvjm/wireless_usb_doesnt_save_network_passphrase/

johnislarry wrote:
So I managed to find a solution to my problem. I don't know if it will help anybody else, but maybe it will. I changed two things. The first was creating a file
/etc/polkit-1/localauthority/50-local.d/org.freedesktop.NetworkManager.pkla
and writing the following lines to it:

[nm-applet]
Identity=unix-group:network
Action=org.freedesktop.NetworkManager.*
ResultAny=yes
ResultInactive=no
ResultActive=yes

That can also be found here https://wiki.archlinux.org/index.php/Ne … ermissions and it allows users in the group "network" to use nm-applet functionalities. The second > thing I changed was commenting out a "no-auto-default" line in /etc/NetworkManager/NetworkManager.conf.
After these changes I am able to use nm-applet as a regular user for connecting to both secured and unsecured networks.

Also note: when saving the wifi passphrase check “Available for all users” before clicking Apply!

Got my TL-WN725N to work on Bee’s BAMT 1.5 and now I can relocate the box into the garage without running a 50 ft cat6 across the house. 🙂 hope this helps.

Monokai For Google Chrome – Inspect Element

monokai-chrome-developer-tools

I found an interesting repository that web developers might find useful. Monokai for the Chrome Developer Tools! Honestly, this makes the Inspect Element UI more readable for me. I often find myself staring at the source code for hours until my eyes bleed. Now if only I could remember how to style view-source…

Link to the repository:

https://github.com/bjmatt/monokai-theme-chromedevtools

How To Push To Github And WordPress.org

I think this is really important and not many people are aware of this. Evan Solomon deved a tool called Scatter. There are a lot of us that favor utilizing Git > SVN, I feel like SVN is stepping backwards in time. Everyone that is current on Git or started out primarily on git may be turned off by SVN. Welp, kick it in the nuts.

http://evansolomon.me/notes/git-wordpress-plugins-and-a-bit-of-sanity-scatter/