All of the following information is based on go version go1.17.1 darwin/amd64
.
GOOS | Out of the Box |
---|---|
aix |
✅ |
android |
✅ |
# it turns out that puttygen can do almost all conversions anyway | |
: ' | |
ssh-private-public - Convert an openssh private key to an openssh public key | |
Usage: ssh-private-public <path-to-key> <path-to-key.pub> | |
' | |
ssh-private-public () { | |
ssh-keygen -f "$1" -y >"$2" | |
} |
(function (app , _, model, $) { | |
/** | |
* @extends {Backbone.Collection} | |
* @type {app.collections.collectionAbstract} | |
*/ | |
app.collections.collectionAbstract = Backbone.Collection.extend({ | |
modelName: 'abstractModel', | |
model: model, | |
urlType: '', | |
urlParam: '', |
Dockerfile
that is based on your production image and
simply install xdebug
into it. Exemple:FROM php:5
RUN yes | pecl install xdebug \
&& echo "zend_extension=$(find /usr/local/lib/php/extensions/ -name xdebug.so)" > /usr/local/etc/php/conf.d/xdebug.ini \
apt-get clean autoclean | |
apt-get autoremove --yes | |
rm -rf /var/lib/{apt,dpkg,cache,log}/ |
# Set variables in .bashrc file | |
# don't forget to change your path correctly! | |
export GOPATH=$HOME/golang | |
export GOROOT=/usr/local/opt/go/libexec | |
export PATH=$PATH:$GOPATH/bin | |
export PATH=$PATH:$GOROOT/bin |
package main | |
import ( | |
"encoding/json" | |
"fmt" | |
"gopkg.in/mgo.v2" | |
"gopkg.in/mgo.v2/bson" | |
"log" | |
) |
Magic words:
psql -U postgres
Some interesting flags (to see all, use -h
or --help
depending on your psql version):
-E
: will describe the underlaying queries of the \
commands (cool for learning!)-l
: psql will list all databases and then exit (useful if the user you connect with doesn't has a default database, like at AWS RDS)<?php | |
public function process(ContainerBuilder $container) | |
{ | |
$factory = $container->findDefinition('app.doctrine.repository.factory'); | |
$repositories = []; | |
foreach ($container->findTaggedServiceIds('app.repository') as $id => $params) { | |
foreach ($params as $param) { | |
$repositories[$param['class']] = $id; |