Posted by & filed under Webdev.

Really fast deployer and server automation tool

mina_logo

Mina lets you build and run scripts to manage your app deployments on servers via SSH.

Mina works really fast because it’s a deploy Bash script generator. It generates an entire procedure as a Bash script and runs it remotely in the server.

Compare this to the likes of Vlad or Capistrano, where each command is ran separately on their own SSH sessions. Mina only creates one SSH session per deploy, minimizing the SSH connection overhead.

$ mina deploy --verbose

-----> Creating the build path
       $ mkdir tmp/build-128293482394
-----> Cloning the Git repository
       $ git clone https://github.com/nadarei/flipstack.git . -n --recursive
       Cloning... done.
-----> Installing gem dependencies using Bundler
       $ bundle install --without development:test
       Using i18n (0.6.0)
       Using multi_json (1.0.4)
       ...
       Your bundle is complete! It was installed to ./vendor/bundle
-----> Moving to releases/4
       $ mv "./tmp/build-128293482394" "releases/4"
-----> Symlinking to current
       $ ln -nfs releases/4 current
-----> Launching
       $ cd releases/4
       $ sudo service nginx restart
-----> Done. Deployed v4

Github Project Home

Posted by & filed under Webdev.

Here is my list of developer goals for 2015:

  • Start new project
  • Raise my Python skills
  • Read at least 10 books about development
  • Learn at least 2 new technology/framework

Posted by & filed under Webdev.

Flask is a microframework for Python based on Werkzeug, Jinja 2 and good intentions. And before you ask: It’s BSD licensed!

Flask is Fun

from flask import Flask
app = Flask(__name__)

@app.route("/")
def hello():
    return "Hello World!"

if __name__ == "__main__":
    app.run()

And Easy to Setup

$ pip install Flask
$ python hello.py
 * Running on http://localhost:5000/

Interested?

Posted by & filed under Webdev.

vagrant is a tool for building complete development environments. With an easy-to-use workflow and focus on automation, Vagrant lowers development environment setup time, increases development/production parity, and makes the "works on my machine" excuse a relic of the past. Vagrant also supported by PHPStorm

Windows setup: VirtualBox + Vagrant
OSX setup: Parallels + Vagrant

Online image setup https://puphpet.com/
Big image collection http://www.vagrantbox.es/

Posted by & filed under Webdev.

Behat is a php framework for testing your business expectations.

Behat is a tool that makes behavior driven development (BDD) possible. With BDD, you write human-readable stories that describe the behavior of your application. These stories can then be auto-tested against your application. And yes, it’s as cool as it sounds!

For example, imagine you’ve been hired to build the famous ls UNIX command. A stakeholder may say to you:

Feature: ls
  In order to see the directory structure
  As a UNIX user
  I need to be able to list the current directory's contents

  Scenario: List 2 files in a directory
    Given I am in a directory "test"
    And I have a file named "foo"
    And I have a file named "bar"
    When I run "ls"
    Then I should get:
      """
      bar
      foo
      """

Posted by & filed under Webdev.

This is boilerplate markup (a blank HTML document template) for HTML5-capable web pages.

<!DOCTYPE html>
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title></title>
<meta charset="utf-8">
<meta name="description" content="">
<meta name="author" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="">
<!--[if lt IE 9]>
<script src="//cdn.jsdelivr.net/html5shiv/3.7.2/html5shiv.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
<link rel="shortcut icon" href="">
</head>
<body>
<!-- Place your content here -->
<!-- SCRIPTS -->
<!-- Example: <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> -->
</body>
</html>

Copy-and-paste the code template above in a new HTML document and then fill out the blanks.
Github @sixrevision
Read more »

Posted by & filed under Webdev.

Снимок_экрана_070614_051958_PM

Рефакторинг — это контролируемый процесс улучшения вашего кода, без написания новой функциональности.

Простые и понятные рекомендации к рефакторингу, собранные в одном месте.

Пользуемся http://refactoring.guru/ и добавляем в закладки.

Posted by & filed under Webdev.

Untitled___Flickr_-_Photo_Sharing_

Like any scripting language, PHP can be used in a variety of applications. The down-side for most programmers is that when they learn how to write PHP, they do not always learn how to write PHP with speed and optimization in mind. This article addresses most common ways you can improve your code with minor changes that will yield large gains as well as teach you how to become a better PHP developer.

One of the most important things you can do when improving PHP application performance is begin measuring your application to find a baseline performance time for different parts of your application. If you do not know which parts of your application are slow or have bottlenecks, you will not know where to begin optimizing your code for better performance. There are many commercial and free applications that can be used to measure PHP performance. See the article PHP Profilers Compared for further information.

Read more »