Skip to content

Instantly share code, notes, and snippets.

View vranac's full-sized avatar

Vranac Srdjan vranac

  • Novi Sad, Vojvodina, Serbia
View GitHub Profile
@funkatron
funkatron / xdebug_codebug_setup.txt
Last active September 8, 2016 19:21
Settings for XDebug and Codebug so PHP debugging actually fucking works
Codebug config======================
Paths
LOCAL REMOTE
/local/path/to/php/app /server/path/to/php/app
xdebug config=======================
root@ed:/vagrant/projects/acp/frontend/app# more /etc/php5/fpm/conf.d/20-xdebug.ini
; configuration for php xdebug module
@cowlby
cowlby / collection_widget.twig
Created October 17, 2011 23:32
Customizing form collections in Symfony2
{% block collection_widget %}
{% spaceless %}
<div class="collection">
{% if prototype is defined %}
{% set attr = attr|merge({'data-prototype': block('collection_item_widget') }) %}
{% endif %}
<div {{ block('widget_container_attributes') }}>
{{ form_errors(form) }}
<ul>
{% for rows in form %}
@chrisroos
chrisroos / gpg-import-and-export-instructions.md
Created September 9, 2011 10:49
Instructions for exporting/importing (backup/restore) GPG keys

Every so often I have to restore my gpg keys and I'm never sure how best to do it. So, I've spent some time playing around with the various ways to export/import (backup/restore) keys.

Method 1

Backup the public and secret keyrings and trust database

cp ~/.gnupg/pubring.gpg /path/to/backups/
cp ~/.gnupg/secring.gpg /path/to/backups/
cp ~/.gnupg/trustdb.gpg /path/to/backups/

or, instead of backing up trustdb...