Vim: statusline and git customizations

Working with lots of projects at the same time in qobo.biz, I started to get confused on which branch I’m currently working. Going back to the terminal, to check the diffs and commits, became a time waste in my daily routine, so I took a break during lunch, to get my vim plugins an upgrade. The catch of the day is the following: Vim-Airline Vim-Airline is a powerful status/tabline facelift of a default statusline with lots of customizations, and useful information on the files you work with. It nicely fits solarized theme, has color shift on different modes: ...

November 23, 2016 · 2 min · anvyst

Definition of "done"

It’s been a long way for the definition to get to this blog post, so i’ll choose the one which favors the most, meanwhile its revision history: Paul M Jones: Definition of “Done” [2016] Mehdi Khalili: Definition of “Done” in MVC project [2011] Paul Stovell: “Done” criteria [2010] AgileFAQ: definition of “done” [2007-10] An example Story definition of done would look like this. All story should have automated acceptance test. The story should have working code supported by unit test that provide around 60 – 70 percent coverage. The story should have well defined acceptance criteria. The code must have been written as a pair or should be code reviewed. Code must be completely checked in to the source control system and the build should pass with all the automated tests running. The product owner must accept the story. Sprint Definition of done: Product owner should have defined a sprint goal. All stories completed for the spring must be accepted by the product owner All the automated acceptance tests should be running for the stories in the sprint. All code should have been pair programmed or must have gone thorough a code review process. If there is a database involved, the database scripts must have been automated and tested. Release Definition of done Product is deployed to the test box and makes it to staging Product has a formal release date. There are deployment documents for the release Training manuals are available for users. All stories for the release are completed and accepted. The release does not have any level one bugs. ...

November 20, 2016 · 2 min · anvyst

We are going to build a framework!

🎶 We're Gonna Build a Framework 🎶 by @dylanbeattie This is absolutely amazing 😂😂😂 pic.twitter.com/xLi88jWZ2B — DEV Community (@ThePracticalDev) November 14, 2016 And they built it!

November 20, 2016 · 1 min · anvyst

PHP: Array vs ArrayObject benchmarking

Some measurements on Arrays vs ArrayObjects found among gist users. Just going to bring it here, in case gist dissappears. # php -v PHP 5.3.6 (cli) (built: Mar 17 2011 20:58:15) Copyright (c) 1997-2011 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2011 Zend Technologies # echo '<?php $s = array(); for($x=0;$x<1000;$x++){ $s[] = array("name"=>"Adam","age"=>35); }; echo memory_get_peak_usage(); ' | php 655040 # echo '<?php $s = array(); for($x=0;$x<1000;$x++){ $o = new ArrayObject; $o->name = "Adam"; $o->age = 35; $s[] = $o;} echo memory_get_peak_usage(); ' | php 887984 # time echo '<?php $s = array(); for($x=0;$x<100000;$x++){ $o = new ArrayObject; $o->name = "Adam"; $o->age = 35; $s[] = $o;} echo memory_get_peak_usage(); ' | php 61010784 real 0m1.448s user 0m1.208s sys 0m0.231s # time echo '<?php $s = array(); for($x=0;$x<100000;$x++){ $s[] = array("name"=>"Adam","age"=>35); }; echo memory_get_peak_usage(); ' | php 33647944 real 0m0.525s user 0m0.429s sys 0m0.092s We can conclude the following at least in PHP 5.6: ...

November 16, 2016 · 2 min · anvyst

Qobo: first month benchmark

It’s been already one month since I moved to Qobo Ltd, as a backend developer, so it’s about time to do some benchmarks on the work done. Open-Source The level of open source involvement of Qobo is enormous. All the projects I’ve been involved in before were always about open-source: it was either based on open-source, or using open-source solutions into some extend. Every time it ends up locking down the solutions for indoor use. It was either features the company didn’t want to share with the open-source community, or key business aspects that were crucial for competitive advantage. The story repeats over and over - the level of feedback to open source was minimal. ...

November 15, 2016 · 2 min · anvyst

Yarn: package manager for JS modules

Yarn kitty rocks! Yarn is a package manager for your code. It allows you to use and share code with other developers from around the world. Yarn does this quickly, securely, and reliably so you don’t ever have to worry. Yarn allows you to use other developers’ solutions to different problems, making it easier for you to develop your software. If you have problems, you can report issues or contribute back, and when the problem is fixed, you can use Yarn to keep it all up to date. ...

November 12, 2016 · 1 min · anvyst

Base32 advantages over Base64

I stumbled upon these little facts, why engineers chose Base32 over Base64 for shared secret key: The resulting character set is all one case, beneficial when using a case-insensitive filesystem, spoken language, or human memory. The Base32 result can be used as a file name because it can not possibly contain the '/' symbol, which is the Unix path separator. To avoid similar-looking pairs of different symbols they picked an alphabet , so the strings can be accurately transcribed by hand. 4. Base32 result excluding padding can be included in a URL without encoding any characters. I’m sure everyone mixed 'I','B','0' and '1','8','0' in hist life. RFC 4648 omits these symbols. ...

October 29, 2016 · 1 min · anvyst

HipChat 4 for Fedora

For some weird reason, HipChat (v4) wasn’t introduced in the downloads page of the official site. It has only .deb package, but there’s a link in JIRA ticket with the rpm sources: [atlassian-artifactory] name=Atlassian-artifactory baseurl=http://atlassian.artifactoryonline.com/atlassian/hipchat-yum-client enabled=1 gpgcheck=0

October 27, 2016 · 1 min · anvyst

Database design: when in doubt - use meta tables

It’s becoming quiet intriguing when you work with the 3rd party closed-source projects. You can see how the project was maturing, and how things were changing on the fly. Especially when you have to plug in some extra logic on top of it, and the code is obfuscated, so the only way how to find all ins and outs - check the database schema. Certain systems force to develop evil workarounds to coupe with bad design practices, whether it’s code or database wise. ...

September 22, 2016 · 2 min · anvyst

Twitter as communication tool for botnets

ESET researchers discovered an Android backdoor Trojan controlled by tweets. Detected by ESET as Android/Twitoor, it’s the first malicious app using Twitter instead of a traditional command-and-control (C&C) server. After launch, the Trojan hides its presence on the system and checks the defined Twitter account in regular intervals for commands. Based on received commands, it can either download malicious apps or change the C&C Twitter account to another one. “Using Twitter to control a botnet is an innovative step for an Android platform,” says Lukáš Štefanko, the ESET malware researcher who discovered the malicious app. ...

August 26, 2016 · 2 min · anvyst