Skip to content

Instantly share code, notes, and snippets.

Avatar

Cedric Ziel cedricziel

View GitHub Profile
@cedricziel
cedricziel / publish_post.json
Created Aug 9, 2020
Canva.com Publish Extension Request Schema
View publish_post.json
{
"user": "userid",
"brand": "brandid",
"label": "Publish",
"message": "message provided",
"assets": [
{
"url":"https://s3-url",
"type":"PNG",
"name":"0001-9416535780.png"
@cedricziel
cedricziel / README
Created Feb 4, 2020
Simple setup for keycloak and docker.
View README
* run gen_keys.sh
* run keycloak_server.sh
Take a look at kcadm on how to import more diverse data points like idp metadata and client configurations.
Also take a look at the simple import / export stuff at https://hub.docker.com/r/jboss/keycloak/
View keybase.md

Keybase proof

I hereby claim:

  • I am cedricziel on github.
  • I am cedricziel (https://keybase.io/cedricziel) on keybase.
  • I have a public key ASAfgwH_iPnBRuetEupEV-aAKQeFZyvkiw-Rop-5rRCSogo

To claim this, I am signing this object:

@cedricziel
cedricziel / RealUrlAutoconfHook.php
Created Feb 1, 2017
Find all plugins of a specific type and attach fixedPostVars to them
View RealUrlAutoconfHook.php
<?php
namespace My\Ext\Hooks;
use TYPO3\CMS\Backend\Utility\BackendUtility;
class RealUrlAutoconfHook {
/**
* @param array $params
View composer.json
{
"require": {
"tm/tooly-composer-script": "^1.2"
},
"require-dev": {
"escapestudios/symfony2-coding-standard": "~2.0"
},
"scripts": {
"post-install-cmd": [
@cedricziel
cedricziel / migrate.sh
Created Jan 12, 2017
Very simple migration script to move from gitlab to gogs
View migrate.sh
#!/bin/env bash
## Needs `jq` (https://stedolan.github.io/jq/) on PATH
## and a personal gogs token of yours.
## Obtain token from https://git.example.com/user/settings/applications
## Usage:
## ./migrate.sh $clone_url $project_name [$optional_group]
## Migrate a repository to gogs into the user namespace of the token-user
## ./migrate.sh git@mygitlab.com:group/repo.git repo
## Migrate a repository to gogs into the group namespace `group` (needs to exist)
View ext_typoscript_setup.txt
config.tx_extbase {
persistence {
classes {
Vendor\MyExt\Domain\Model\Address {
mapping {
tableName = tt_address
# optional. if you have added additional fields f.e.
columns {
tx_foo_description.mapOnProperty = description
tx_foo_my_other_column.mapOnProperty = unusualPropertyName
View EntityRouter.php
<?php
namespace AppBundle\Routing;
use AppBundle\Entity\RoutableEntityInterface;
use JMS\I18nRoutingBundle\Router\I18nRouter;
/**
* Class Router
* Overrides the I18n router to be able to resolve objects by route
@cedricziel
cedricziel / CustomerAutocompletion.php
Created Nov 4, 2016
TYPO3 CMS 7 fully loaded TSFE in EiD
View CustomerAutocompletion.php
<?php
namespace Project\Namespace\Hooks;
use Psr\Http\Message\ResponseInterface;
use Psr\Http\Message\ServerRequestInterface;
use TYPO3\CMS\Backend\Utility\BackendUtility;
use TYPO3\CMS\Core\Core\Bootstrap;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
use TYPO3\CMS\Core\Utility\GeneralUtility;
@cedricziel
cedricziel / FacebookVideoHelper.php
Created Oct 7, 2016 — forked from spoonerWeb/FacebookVideoHelper.php
Facebook video integration in TYPO3 (needs some love for FE rendering)
View FacebookVideoHelper.php
<?php
namespace Vendor\ExtensionKey\Helpers;
/**
* This file is part of the TYPO3 CMS project.
*
* It is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License, either version 2
* of the License, or any later version.
*