uxCATling - how i make my pc tell me when it's time to vote at 100% using linux

in #rudyardcatling6 years ago (edited)

edit : celeroncat@cerebro ~/Documents/steemUX $ date --iso-8601=seconds
2018-04-30T02:19:19+02:00

yagh i'll clean up the mess but i got shit on the stove so i'll just put it here cos this seems to work regardless of day diff and what not, i can't just make a new post every time i pat myself on the eureka back so i edit, for now, 't is no bother trying, this is me and this is how i chaos, now, before my stuff burns ... brb

well its not github and i'm not really trying to educate although if anyone gets anything from anything i say i guess thats a nice bonus. It's just my journey as i dive nose first below the surface. I forgot
in the underground is where the shadows are

snippet number two .. before i start crontabbing on a newly formatted machine i think i best collect a few working bits

so after how much money is my l33t vote worth at 100% (about almost half an sbdcent atm now btw ... i am made of ubber)

i thought , since i try to stick to 100% votes unless i go afk for more than two hours ... (in which case i do max 4 or 5) something to make some noise when its about time would have been quite useful so i gets to digging

i put on my robe and wizard hat , light some candyls and pray to the 1e100 because even if i had a head for long term storage i still think most of the time syntax is a waste of brainspace. I take my other scribbles, open up and start "mucking about", oldskool c64 music in the background, speakers loud enough to kill the background noise of hell
and some hours later i think i have a werking v0.0 version, which probably can be easily adapted to just running on crontab but

if i use the command


watch -n 300 ./vote100notify_wrk.sh @rudyardcatling

all prepacked with standard linux mint install, no need for apting fresh packages
teknikley (i do that for that gremmernazibot) you can run each and any of these scripts in separate terminal windows for several accounts at once, they will not interfere with each other but it might get noisy if six start speaking at once ofcourse , if i do the previous in one terminal and then in another
watch -n 300 ./vote100notify_wrk.sh @ubasti

and if need be run the tellmemyvoteworth script in another every 5 minutes or hour it won't collide, but i have no clue how far it goes before either belgium tries ruining it or i get bored with it ... variables

it runs in terminal , every 5 minutes (300 seconds) , checks ... then uses another nice little prepacked tool called espeak to speak to me , how many seconds left (on approximation) before i can do a 100% vote again

i'm hanging round here all day anyway, and thats what computers are for right (i mean besides free porn ofcourse)
to help lazy people like me out

#!/bin/bash

##################################
#./vote100notify_wrk.sh
##################################
ACCOUNTHANDLE=$1
##################################

ACCOUNTHANDLE="$ACCOUNTHANDLE.json"
DOMAIN='https://steemit.com/'
CURLURL="$DOMAIN$ACCOUNTHANDLE"

wget -qO- $CURLURL |gunzip >jsondata
cat jsondata |./pretty_please.sh >jsondataa
vpvar=$(cat jsondataa |grep -oP '(?<=("voting_power":)).*(?=(,))')

if [ "$vpvar" == "10000" ]
then 
espeak "time to vote"
exit
fi
lasttimevar=$(cat jsondataa |grep -oP '(?<=("last_vote_time":")).*(?=(",))')
lasttimevar=$(date -d"$lasttimevar" +%s) 
lasttimevar=$(($lasttimevar+7200))
curtimevar=$(date --iso-8601=seconds)
curtimevar=$(date -d"$curtimevar" +%s)
echo "current voting power:"$vpvar
echo "last voting time: "$lasttimevar
echo "current time    : "$curtimevar
lapstimevar=$(($curtimevar-$lasttimevar))
echo "elapsed         : "$lapstimevar
estimatedleftvar=$((8640-lapstimevar))
echo "estimated(??!?) : "$estimatedleftvar
espeak $estimatedleftvar"seconds left before voting"$1
rm jsondata
rm jsondataa

and it works ... YO LO, all hail the me, and i got something to post today that's not a re-steem or something i try to hard to type together and ends up like a fabricated popsong

i made a slight alteration to the other one

https://steemit.com/rudyardcatling/@rudyardcatling/uxcatling-how-i-get-the-value-of-my-100-vote-using-linux-shell-script-and-steemdb-v0-01

so i can pass usernames as arguments on the commandline

YAY COMMANDLINE !

because that is how its done after all, now i can use any account name with either script and it will give me the goodies ...

so then phoneboy comes in with mister formal Ed and goes like icandothatfaster

i'm not competing bro, ... this is what i did today, its time to eat

enjoy, or not, or enjoy something else

or not

i'm not a content nazi and i'm not looking for a position in the spotlight either ...

#rudyardcatling #ucxatling #linux #api #steemit #linuxfoundation #scripting #coding #programming #votes #votepercentage #howto #unix #bash

i think i got the timeframe about right this time, it does seem to converge with the major sites and tools but .. that will need observation ofcourse

have a nice day ...! remember , downvoting is so passé ... mute what you dont wanna hear and it will never bother you again and you'll make no enemies

image from ... guess from where ... (logos from 'by me' and stuff)

how many posts does one make a day ... how many re-steems ? what's considered spam ... its a huge place but this is not twitter ... you gotta go measuring risk / reward ratios and what not ... i thought five but i can't do five and not neglect some people, i thought ten but i think ten is TOO much so ... i guess i vary, one own-post a day however is probably not a bad idea since i'm not one of those dudes raking in $100 or more after the first five minutes lol

so well , slowly but without fear of ever quitting i guess it doesnt go down so what's to lose

here's hoping this is the last edit to this post until v0.01 is presentable
asking you say ,

where's the fun in that, sounds like teamwork

makes my skin itch

o yes i do, i do understand how it does collide when running at the exact same time in the same folder because of the filenames right, ofcourse well ... doesnt seem too hard to fix, if it needs fixing at all, i'm not sure if bashdash has provisions for same scripts running simultaneously becaue lockfile doesnt seem good idea since its timebased, but a different folder should fix it nicely in any case but thanks, but it would be nice if someone could answer in the dev channel believe me or not this is driving my oldskool brain pretty dam crazy and i can assure you i got enough on my plate here in hell, if you can help, you can maybe help get me out faster, save the state some money because i wont need their blood money anymore and if you want taxes ask those who cost you, not me ... if i cost nothing thats 1000s saved, i'll go for that

Sort:  

oh you quoted one of my favorite hero's Linus Torvalds, hey did ever try running this code on your phone?

lol, i think he's closer to some kind of demi-god, like satoshi nakamoto, whoever that might have been, doing all that, then giving it away for free like : "*o well i don't care, i'm so good i can make money before breakfast then do whatever the fuck i want" and then DO it, i mean its not all talk, right. GIving tools like that to the masses ?

on my phone hm ? ...

a tempting idea however its not the working version as i found out by now, for some reasont the https://steemit.com/@username.json has been presenting a value of 9222 sine this noon wehn i made four votes and took to bed, and its still displaying that, so either that's a cache thing or a bandwidth thing or something whatever i dont have a clue about. If i look at steemnow.com (@penguinpablo - i believe you told me about it i'm not sure) the ticker is right, it sayd how much there is so there must be something else i can poke and extract, or i'm getting the wrong data after poking too much (like every 5 minutes)

it doesn't really come with a manual lol.png

but that's half the fun, i should say 'interesting'

i'm not sure how to run bash scripts on my ancient kitkatphone with 512 mb internal memory lol but i have this thing i bought last year called appgamekit , by gamecreators which writes in some kind of basic but compiles to windows, linux, mac and droid alike (or so they claim) so if i wanted that id probbaly use that but if ican get a folder of snippets to run on my always online box that would be very much to my liking ...
the first script on voting power is tried and tested, uses commandline arguments so i could go ./wurdamoney.sh @darsico , just as easy as ./wurdamoney.sh @rudyardcatling and it tells me the worth of a 100% vote (kudos btw :D)

but this one needs work, i cant just have data that doesnt update, can i, and if the bigguns get it right that means i can too

if it's up i should at least have webside front so i could , i guess run it on everything that has a browser, including a phone :)

thanks for the vote btw, much appreciated iTHANKS!.png

tsch, lets hope Cooke doesn't sue me for cosplaying iThings

ah : p.s. ... i just bumped into something you'll probably find interesting too considering your line of work and fields of interest (as far as i know xD)

https://medium.freecodecamp.org/stack-overflow-2018-developer-survey-faac8d3eb357

no referral link or anything, if you havent done three articles this week they should let you read without membership

ever use "sublime" to write with? if you could put it in an app like *apk you might create a bot one day your already there. Really if my phone could run my voting bot now that would be cool :))

first time i hear of it .... i havent really done anyting with appgamekit either so far i bought it in december before i fell into the darkness again but

they got this thing here

https://play.google.com/store/apps/details?id=com.thegamecreators.agk_player2&hl=nl

which you can use to actually run your code on a phone before effectively trying to push it up on the appstore, it comes with full documentation and there's zero license other than the cost of buying the program to program

but i'll check into this sublime thing too, thanks :)

ahuh, i just checked it ... i got a flash on the script and that should be doing what it needs to do now, at rudimentary level, i see its an editor ... i thought it was some kind of special phone language or compiler :) thats what i get for having my head in 11 dimensions strung hyper all the time but i can't help that ... maybe it goes away sometime ever but i doubt it, its been like that too long ... and diverging ... also a specialty.
It looks fair enough but frankly i rarely install any of these tools. Xed is all i need because the bit of snippet i come up with isnt exactly rocket science code lol. No need for special tools that organize my k-locks or make it shiney. The more minimal i can keep the system the more it feels comfortable to me really (well , for this ofcourse, my windows pc still has a 970gtx in it, which isnt max but also not minimal). The standard linux editor recognizes quite some tags and syntax and for bash scripting its the perfect lightweight tool afaik. The rest is just distraction ... like someone buying a brandnew €5000 rig only to go sit in front of it and be mindblocked and then that big 4k screen didnt seem to help after all, y know what i'm saying.

If i understand correctly you would like to run your phone as a server where your bot runs completely on the phone itself and the phone is not just an interface to connect to the server .. I'm gonna admit honestly i know ZERO about phone apps, its all custom linux versions, wether its android or mapple but
i dont know , maybe there's security stuff or something that would prevent it, id have to spend more than a few days praying to the 1e100 to get an idea of that i'm afraid.
anyway you would need like a dedicated phone for that then, its has to be always on and always connected and give priority to whatever the server is for. Im curious ofcourse but seeing as my smartphone doesnt even have a simcard with a number in it i cant say im the most up to date phoneboy this side of the planet. I use it for basically nothing but wechat, line and whatsapp and the flashlight comes in really handy lol.png

wow dear, i got another page already ... if i keep doing this the steem blockchain will be in the petabytes in no time. I actually wonder what they do for storage and who all keeps a running blockchain seeing as if the classic principle applies that you need a democratic majority to take it all over they have to have several nodes but seeing the amount of data put on it, including pictures that thing's gotta be huge by now, its not just a chain of hashes, its got all kinds of stuff on it, unless they use something separate for storage but that would mean its pretty easy to censor afterwards instead of the other way round

so many question ... so few lives

...

i understand myself one little syntax error like a colon can throw everything in to chaos sometimes in and out of java script and php can be tricky myself i use Xml and javex okay just a joke but i do use Ajax and it all works well :))
and as far as i have heard at somepoint videos and pics can be stored elsewhere maybe off the blockchain and deleted if not used over a period of time. Hey is that your bot?

i see ... so its not all that "uncensorable" then after all, i thought it almost impossible to sustain a complete blockchain with like googlesize youtube data and keep copies of that on several physical locations, layered realities ... so accounts arent safe either in that case, you could just be kicked out one moment to the next and that 5million sp gone and confiscated by the ceo hm ?

i already thought of finding some devs and asking how they see "protected" joint accounts like @steembasicincome because , lets be real about it, as humane as one might be it's still humans so once the numbers get large enough if one man can take one key, the money and run, it becomes statistically ever more likely that someone will. Even over a stupid fallout over what colour to use on the frontpage of the flyer or something. That's what humans do after all and i don't consider anyone who holds sole power to be immune to that, not world leaders, not hackitivists, not cutting edge social workers lol ...

protection against removal, protectionst against one guy or gal running off with the loot everyone worked so hard for and got so many people together for

there should be some failsafes,not just a three month withdrawal period, it needs something like launching a nuke, two keys that need to be turned simultaneously in two keyholes or two fingerprints (nah fingerprints proved to be just that on the previous apple after three days lol)

it would be a shame to see something destroyed over a stupid quarrel

well yea and the programming, a shiney editor like that certainly helps with bigger stuff where you can't see the nesting through the lines anymore or that one delimiter somewhere you can't see after eight hours straight and it starts looking like lettersoup, thats where a spellchecker and colourcodes definitely come in handy. The basic whitespace and brackets around variables when substituted in bash get me every time ... or a whitespace too much when a ="this" while it should be a="this", syntax is a bitch lol

i got a small worry about the EU 'right to be forgotten' law too , google just lost one on that, how a blockchain based network will do that when someone complains ...

i hope no one does before i can take my millions out (lmao) fifty years from now when i make my first at this rate ... i read a lot on this ting with delimiters or carriage returns at the end of a line but basically a return is just another character, just one you can't see on your screen, right ? i never understood what they were on about

but i get that a lot ... offworldly lol ... ooh my scripts been running all night since i edited it and the timer is on spot, i should pat myself
, all that needs is a small bit for when the vote is ready but not cast yet and i can use it as a command , o YEA ... now for that 25000 sp i'm missing to make it sustainable

think.png

Coin Marketplace

STEEM 0.18
TRX 0.16
JST 0.029
BTC 62299.02
ETH 2440.23
USDT 1.00
SBD 2.65