Skip to content

Instantly share code, notes, and snippets.

@michaelklapper
michaelklapper / .bashrc
Created December 30, 2013 23:30
Color up your bash history with the date time information of called commands.
MY_BASH_BLUE="\033[0;34m" #Blue
MY_BASH_NOCOLOR="\033[0m"
HISTTIMEFORMAT=`echo -e ${MY_BASH_BLUE}[%F %T] $MY_BASH_NOCOLOR `
HISTSIZE=20000
HISTFILESIZE=20000
Handy one-liners for SED
HANDY ONE-LINERS FOR SED (Unix stream editor) Mar. 23, 2001
compiled by Eric Pement <pemente@northpark.edu> version 5.1
Latest version of this file is usually at:
http://www.student.northpark.edu/pemente/sed/sed1line.txt
http://www.cornerstonemag.com/sed/sed1line.txt
This file is also available in Portuguese at:
http://www.lrv.ufsc.br/wmaker/sed_ptBR.html
@michaelklapper
michaelklapper / knife.solo.rst
Created October 17, 2013 12:09
How to bootstrap and provision a server with knife solo
// DAM settings
t3lib_div::loadTCA('tx_dam');
t3lib_div::loadTCA('tx_dam_cat');
//Disable DAM versioning
$TCA['tx_dam']['ctrl']['versioningWS'] = 0;
$TCA['tx_dam_cat']['ctrl']['versioningWS'] = 0;
$TCA['tx_dam']['ctrl']['versioningWS_alwaysAllowLiveEdit'] = 1;
$TCA['tx_dam_cat']['ctrl']['versioningWS_alwaysAllowLiveEdit'] = 1;
[miscellany]
global-ignores = *.o *.lo *.la #*# .*.rej *.rej .*~ *~ .#* .DS_Store build dist target
enable-auto-props = yes
[auto-props]
*.c = svn:eol-style=native;svn:keywords=Date Author Id Revision HeadURL
*.cpp = svn:eol-style=native;svn:keywords=Date Author Id Revision HeadURL
*.h = svn:eol-style=native;svn:keywords=Date Author Id Revision HeadURL
*.dsp = svn:eol-style=CRLF
*.dsw = svn:eol-style=CRLF

Context

In the Google Summer of Code Project "TYPO3 Flow meets Ember.js" we are trying to make the server-side framework TYPO3 Flow and the client-side framework Ember.js (using Ember Data as the persistence layer) work together easily through conventions and a powerful scaffolding mechanism. You can visit our website to see a more detailed concept.

This document gives a short introduction of:

  • how domain models look like in Flow and Ember Data,
  • how the REST JSON API is expected to look like (to follow Ember Data conventions),
  • for which models REST APIs are provided and how.
@michaelklapper
michaelklapper / phpstorm_enable_debugging.sh
Created July 2, 2013 14:09
phpstorm enable command line debugging
export XDEBUG_CONFIG="idekey=PHPSTORM remote_port=9000"
export SERVER_NAME=sandbox
@michaelklapper
michaelklapper / add_solr_document.sh
Created July 2, 2013 13:45
Solr: Create new document with curl
curl http://localhost:8095/solr/test/update --data-binary '<add><doc><field name="id">1</field><field name="type">website</field><field name="appKey">indexer</field><field name="title">My product</field><field name="price_mz_f">49.99</field><field name="price_fr_f">43.99</field><field name="price_st_f">23.99</field></doc></add>' -H 'Content-type:text/xml; charset=utf-8'