Yii2 projects alternative organization

How is it supposed to create Yii2 project now? Choose template project: basic or advanced, fork it then edit and commit right there. Wham! You've made copy-pasting! Your project and the template develop separately since now. You will not get fixes to the template. And your improvements that are specific for your tasks will not be accepted into yii2-app-basic. This is the problem number one.

How is it supposed to evolve Yii2 project? Choose suitable extensions and plug them in with composer. Then you find example config for the extension in it's README and copy this example into your application config. Oops... You cook copypasta again! It can make troubles in many ways, e.g. in a big project many extensions can be used — application config becomes just huge and unreadable. This is the problem number two.

I cover these problems together because they are closely related. First one can be solved by separating reusable code and turning it into an extension. But then you've got second problem — extension needs config.

These problems are most acute for repeated projects when you have to deploy many/several similar projects with big/small changes. But removing copypasta and code reuse never hurt anyone.

I want to share my solution for outlined problems.

Full article | Russian version

Created yii2-yandex-metrika

Provides really easy adding Yandex.Metrika counter to site. Even easier then adding a widget into layout.

Works by adding Behavior to the Application View. Behavior listens to EVENT_END_BODY and echos the counter script.

Released Composer Config Plugin 0.2.2

CHANGELOG:

  • Improved README (@hiqsol)
  • Added support for .env, JSON and YAML (@hiqsol)

Released Composer Config Plugin 0.2.0

CHANGELOG:

  • Added initializaion of composer autoloading for project classes become usable in configs (@hiqsol)
  • Added work with $config_name paths for use of already built config (@hiqsol)
  • Renamed pathes -> paths everywhere (@hiqsol)
  • Added collecting dev aliases for root package (@hiqsol)

Redone our site with Yii2

Completely redone our site with Yii2.

It's made with HiSite, Pages module and Hyde theme.

Why? I must admit Jekyll is very good for creating simple sites. I just wanted my own Jekyll more extendable and created with tools I'm used to: PHP and Yii.

Released Asset Packagist 0.1.0

Composer

Composer + Bower + NPM = friends forever!

Asset Packagist is the composer compatible repository that allows installation of Bower and NPM packages as native Composer packages.

NO plugins and NO Node.js are required.

https://asset-packagist.org/

https://hiqdev.com/packages/asset-packagist

Released HiDev 0.4.0

CHANGELOG:

  • Changed: redone to composer-config-plugin
  • Changed: greatly improved functional tests
  • Fixed minor issues
  • Added sudo modifier
  • Added @root instead of @prjdir
  • Added hidev help
  • Added copying in FileController
  • Changed require: option to plugins:
  • Added CommandController
  • Added dump/internals action
  • Changed to use hiqdev/composer-extension-plugin instead of PluginManager
  • Added github/create and github/exists actions
  • Changed back to yii2 <- minii, used asset-packagist.hiqdev.com repository
  • Added loading of project's own bootstrap and config
  • Added better defaults when package name is domain
  • Changed github name -> full_name to correspond github api
  • Fixed scrutinizer issues
  • Added smart vendor require in hidev/init
  • Fixed bump and bump/release
  • Added easy creation of templated dirs and files with DirectoryController
  • Fixed JsonHandler to parse empty JSON to empty array (died before)

rEPPy became hEPPy

I had to turn rEPPy to hEPPy to register it to PyPI.
Reppy was already taken. And hEPPy is nice and happy :)

hEPPy is EPP client and library in Python.

EPP is Extensible Provisioning Protocol used for registrar-registry communication to register and manage domains.

hEPPy is gradually approaching state when it's going to be usable.

Created our site with Dr. Jekyll and Mr. Hyde

It was strange case of Dr. Jekyll and Mr. Hyde...

Initially this site was created with Jekyll.
But then I thought it was strange :-/
And we've redone the site with Yii2.

I've kept old version here:

https://github.com/hiqdev/hiqdev.github.io