sudo snap install go --classic
# open these files `nano ~/.profile` or `nano ~/.zshrc` and add below at the end
export GOPATH=$HOME/goproj
export PATH=$PATH:/usr/local/go/bin:$GOPATH/bin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
__author__ = 'M. Taqi' | |
__copyright__ = 'Copyright 2015-16, Cogilent ' | |
__license__ = 'MIT' | |
__email__ = '[email protected]' | |
import base64 | |
import requests | |
import sys, os, re, string, pprint | |
import psycopg2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
How to configure phpStorm with EditorConfig and PHPMD: | |
----------------------------------------------------- | |
PHPMD: | |
------ | |
phpmd (PHP Mess Detector) is a static analysis tool that will find issues in your code you never knew you had. Your code will still run, follow a few of phpmd's recommendations though and it will be better! | |
phpmd is already bundled and enabled in phpstorm, but in order to more easily manage versions and add custom rulesets, you should do the following: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Traits; | |
use Doctrine\ORM\Mapping as ORM; | |
/** | |
* Trait TimeStampTrait | |
* @package App\Traits | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php declare(strict_types=1); | |
namespace App\Controller; | |
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; | |
use Symfony\Component\Validator\ConstraintViolationListInterface; | |
use Symfony\Component\HttpFoundation\Request; | |
use App\Event\RepositoryEvent; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php declare(strict_types=1); | |
namespace App\Event; | |
use Symfony\Contracts\EventDispatcher\Event; | |
/** | |
* Class RepositoryEvent | |
* @package App\Event | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php declare(strict_types=1); | |
namespace App\Controller; | |
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; | |
use Symfony\Component\Validator\ConstraintViolationListInterface; | |
use Symfony\Component\HttpFoundation\Request; | |
use App\Event\RepositoryEvent; | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php declare(strict_types=1); | |
namespace App\Controller; | |
use Symfony\Component\HttpFoundation\JsonResponse; | |
use Symfony\Component\Routing\Annotation\Route; | |
use Symfony\Component\HttpFoundation\Response; | |
use Symfony\Component\HttpFoundation\Request; | |
use Symfony\Component\Serializer\Serializer; | |
use App\Entity\Post; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php declare(strict_types=1); | |
namespace App\EventListener; | |
use App\Event\RepositoryEvent; | |
use App\Services\PostService; | |
use App\Entity\Post; | |
/** | |
* Class PostListener |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This file is the entry point to configure your own services. | |
# Files in the packages/ subdirectory configure your dependencies. | |
# Put parameters here that don't need to change on each machine where the app is deployed | |
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration | |
parameters: | |
services: | |
# default configuration for services in *this* file | |
_defaults: |
OlderNewer