Skip to content

Instantly share code, notes, and snippets.

View xseignard's full-sized avatar
🦄
Internet thuggin'

Xavier Seignard xseignard

🦄
Internet thuggin'
View GitHub Profile
@xseignard
xseignard / java
Created September 30, 2011 09:45
Headless EMF compare on Xtext models
/**
* Launcher of this application.
*
* @param args
* Arguments of the launch.
*/
public static void main(String[] args) {
// Models paths
String model1 = "path/to/my/model1.ext";
String model2 = "path/to/my/model2.ext";
@xseignard
xseignard / My.ecore
Created September 30, 2011 10:13
My.ecore
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="test"
nsURI="URItest" nsPrefix="test">
<eClassifiers xsi:type="ecore:EClass" name="Truc">
<eOperations name="getAllMachins" upperBound="-1" eType="#//Machin">
<eAnnotations source="http://www.eclipse.org/emf/2002/GenModel">
<details key="body" value="EList&lt;Machin> machins = new &lt;%org.eclipse.emf.common.util.BasicEList%>&lt;Machin>(this.getAutresMachins());&#xA;machins.add(0, this.getPremierMachin());&#xA;return machins;"/>
<details key="documentation" value="test"/>
@xseignard
xseignard / gist:1320082
Created October 27, 2011 16:39
Jenkins log
Started by user xavier.seignard@gmail.com
Building remotely on s-4917e264
Checkout:tycho-demo-build / /scratch/hudson/workspace/tycho-demo-build - hudson.remoting.Channel@1fc775a3:s-4917e264
Using strategy: Default
Last Built Revision: Revision a9251095e30f41620529707eec9b24a9f3df1f49 (origin/master)
Checkout:tycho-demo-build / /scratch/hudson/workspace/tycho-demo-build - hudson.remoting.LocalChannel@e415b8
Fetching changes from the remote Git repository
Fetching upstream changes from git@github.com:xseignard/tycho-demo-camp.git
Commencing build of Revision a9251095e30f41620529707eec9b24a9f3df1f49 (origin/master)
Checking out Revision a9251095e30f41620529707eec9b24a9f3df1f49 (origin/master)
[tycho-demo-build] $ /bin/sh -xe /tmp/hudson3925336321685112936.sh
+ export DISPLAY=:1
+ DISPLAY=:1
+ Xvfb :1
_XSERVTransmkdir: ERROR: euid != 0,directory /tmp/.X11-unix will not be created.
Process leaked file descriptors. See http://wiki.jenkins-ci.org/display/JENKINS/Spawning+processes+from+build for more information
@xseignard
xseignard / gist:1366539
Created November 15, 2011 09:18
Attach source for tycho build
<plugin>
<!-- TODO remove workaround when
https://issues.sonatype.org/browse/TYCHO-473
is fixed -->
<groupId>org.sonatype.tycho</groupId>
<artifactId>maven-osgi-source-plugin</artifactId>
<version>${tycho.version}</version>
<executions>
<execution>
<id>attach-source</id>
@xseignard
xseignard / My.ecore
Created November 17, 2011 10:46
My.ecore
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0"
xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="test"
nsURI="test" nsPrefix="test">
<eClassifiers xsi:type="ecore:EClass" name="NumericDataType">
<eTypeParameters name="T"/>
<eOperations name="getMin">
<eGenericType eTypeParameter="#//NumericDataType/T"/>
</eOperations>
@xseignard
xseignard / pom.xml
Created November 22, 2011 09:39
build section of my pom.xml
<build>
<plugins>
<!-- Add generated source directory to the build -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>1.7</version>
<executions>
<execution>
<id>add-source</id>
@xseignard
xseignard / gist:1390741
Created November 24, 2011 06:15
mwe2 log
0 [main] INFO lipse.emf.mwe.utils.StandaloneSetup - Registering platform uri '/Users/xas/Documents/repos/codegeneration-goodies-demos'
279 [main] INFO clipse.emf.mwe.utils.GenModelHelper - Registered GenModel 'http:///org/eclipse/emf/examples/library/extlibrary.ecore/1.0.0' from 'platform:/resource/org.eclipse.emf.examples.library.generationgap/model/extlibrary.genmodel'
282 [main] INFO lipse.emf.mwe2.ecore.EcoreGenerator - generating EMF code for platform:/resource/org.eclipse.emf.examples.library.generationgap/model/extlibrary.genmodel
1263 [main] INFO .emf.mwe2.runtime.workflow.Workflow - Done.
@xseignard
xseignard / gist:1390746
Created November 24, 2011 06:19
my ggp mwe2
module com.test.gap
import org.eclipse.emf.mwe.utils.*
import org.eclipse.emf.mwe2.ecore.*
var projectName = "test-gap"
var runtimeProject = "${projectName}"
Workflow {
bean = StandaloneSetup {
@xseignard
xseignard / buildStatus.py
Created December 2, 2011 09:35
python script to get the status of a jenkins build
#!/usr/bin/python
import json
import sys
import urllib2
import base64
user = XXXXX
password = XXXXX
jenkinsUrl = XXXXX