Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time


This is the project's repository, come here if you found a bug, if you want to request new features or if you want to contribute.

If you need help to use twigfiddle, please read the twigfiddle's help page.

Some words about the project

The project is made of 2 applications:

  • cli directory contains the fiddle runner, an application built using Symfony components to execute a fiddle.

  • web directory contains the web application, built using the Symfony framework

About the other directories:

  • resources directory contains specification documentations, logo source and original integrated design.

  • samples contains exported fiddles (see app/console custom commands)

  • environment is the default directory containing fiddles at runtime

  • debug is the default directory where crashed fiddles are stored


Here are instructions to get started with the application. Of course, replace paths to fit with your own environment.

# Clone the project
git clone twigfiddle
cd twigfiddle

# install Composer
php -r "readfile('');" | php
sudo mv composer.phar /usr/bin/composer
sudo chmod 755 /usr/bin/composer

# Install the fiddle runner and prepare all twig versions
cd cli
composer install
cd twig
cd ../../

# Install the web application
# composer update will fail when trying to remove apc cache, that's normal at this step
cd web
composer install

# Install the database
# You should create it yourself, from mysql, type:
# CREATE DATABASE twigfiddle
# GRANT ALL PRIVILEGES ON twigfiddle.* To '<user>'@'' IDENTIFIED BY '<password>';
php app/console doctrine:schema:drop --force
php app/console doctrine:schema:create
php app/console twigfiddle:import ../samples/*

# Check that everything is working properly
composer update
php app/check.php
phpunit tests

# Launch the application
php app/console server:start

Automatically download, install and configure new Twig releases

Simply run the following command:

php cli/run-prod.php twigfiddle:release:watcher

Upgrade for installs before 01/11/2016

User provider have been refactored ( see #18 ), you need to run the following queries to upgrade twigfiddle schema.

alter table user add column nickname varchar(255) not null after username;
update user set nickname = username;
update user set username = concat('["', resource_owner, '","', resource_owner_id, '"]');

Configure external services

Don't panic, that's optional.

About provides a small development environment to develop, run, store and access Twig code online.








No packages published