Skip to content

Instantly share code, notes, and snippets.

/*
* JBoss, Home of Professional Open Source
* Copyright 2011 Red Hat Inc. and/or its affiliates and other contributors
* as indicated by the @authors tag. All rights reserved.
* See the copyright.txt in the distribution for a
* full listing of individual contributors.
*
* This copyrighted material is made available to anyone wishing to use,
* modify, copy, or redistribute it subject to the terms and conditions
* of the GNU Lesser General Public License, v. 2.1.
private void tick()
{
final long now = System.currentTimeMillis();
while (System.currentTimeMillis() <= now)
sleep(1);
}
@wolfc
wolfc / git-rewrite-email
Created July 16, 2012 08:16
Rename an email address on the current branch
#!/bin/sh
if [ $# != 2 ]; then
echo 1>&2 "Usage: $0 <old-email> <new-email>"
exit 1
fi
export OLD_EMAIL="$1"
export NEW_EMAIL="$2"
git filter-branch -f --env-filter \
'if [ "$GIT_AUTHOR_EMAIL" = "$OLD_EMAIL" ]; then
export GIT_AUTHOR_EMAIL="$NEW_EMAIL"; fi
@wolfc
wolfc / gist:2399025
Created April 16, 2012 14:03
/usr/share/maven-fragments/geronimo-validation
<dependency>
<maven>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-validation_1.0_spec</artifactId>
<version>1.1</version>
</maven>
<jpp>
<groupId>JPP</groupId>
<artifactId>geronimo-validation</artifactId>
<version>1.1</version>
@wolfc
wolfc / gist:2397925
Created April 16, 2012 11:32
Gradle issue
$ gradlehome/gradle-1.0-rc-1-20120416114910+0200/bin/gradle --stacktrace clean
FAILURE: Build failed with an exception.
* What went wrong:
Build aborted because of an internal error.
* Try:
Run with --info or --debug option to get more log output.
java.lang.ClassNotFoundException: org.jboss.dmr.Parser
at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:264)
at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73)
at org.jboss.modules.Module.loadModuleClass(Module.java:517)
at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
at java.lang.ClassLoader.defineClass1(Native Method)
@wolfc
wolfc / archive.sh
Created April 3, 2012 14:44
Create the JBoss AS archive
#!/bin/sh
REPO=$1
TAG=$2
git archive --remote=$REPO --format=tar --prefix=jboss-as-$TAG/ $TAG | xz >SOURCES/jboss-as-$TAG.tar.xz
Error: Package: jboss-as-7.1.0-1.fc17.noarch (/jboss-as-7.1.0-1.fc17.noarch)
Requires: jboss-ejb3-ext-api >= 2.0.0-2
Error: Package: jboss-as-7.1.0-1.fc17.noarch (/jboss-as-7.1.0-1.fc17.noarch)
Requires: jboss-saaj-1.3-api
Error: Package: jboss-as-7.1.0-1.fc17.noarch (/jboss-as-7.1.0-1.fc17.noarch)
Requires: jboss-jsf-2.1-api
Error: Package: weld-core-1.1.5-2.AS71.Final.fc17.noarch (goldmann)
Requires: jboss-interceptor
Error: Package: jboss-as-7.1.0-1.fc17.noarch (/jboss-as-7.1.0-1.fc17.noarch)
Requires: jboss-jstl-1.2-api >= 1.0.3
@wolfc
wolfc / module.xml
Created March 21, 2012 11:40
modules/javax/rmi/api/main/module.xml
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ JBoss, Home of Professional Open Source.
~ Copyright 2010, Red Hat, Inc., and individual contributors
~ as indicated by the @author tags. See the copyright.txt file in the
~ distribution for a full listing of individual contributors.
~
~ This is free software; you can redistribute it and/or modify it
~ under the terms of the GNU Lesser General Public License as
@wolfc
wolfc / gist:2049707
Created March 16, 2012 11:42
mvn 3.0.4
[DEBUG] org.jboss.as:jboss-as-security:jar:7.1.0.Final
[DEBUG] junit:junit:jar:4.10:test
[DEBUG] org.hamcrest:hamcrest-core:jar:1.1:test
[DEBUG] org.jboss.msc:jboss-msc:jar:1.0.2.GA:compile
[DEBUG] org.jboss.as:jboss-as-domain-management:jar:7.1.0.Final:compile
[DEBUG] org.jboss:jboss-common-core:jar:2.2.17.GA:compile
[DEBUG] org.jboss.as:jboss-as-controller:jar:7.1.0.Final:compile
[DEBUG] org.jboss.as:jboss-as-controller-client:jar:7.1.0.Final:compile
[DEBUG] org.jboss:jboss-dmr:jar:1.1.1.Final:compile
[DEBUG] org.jboss.as:jboss-as-server:jar:7.1.0.Final:compile