Netbeans - Single JAR

By qless on Sunday 30 May 2010 21:26 - Comments (6)
Categories: Java, Programming, Tutorial, Views: 5.213

Netbeans is one of the free great Java IDE's, but its default build creates a dist folder with a small jar and a subfolder with the libraries.
In eclipse I had a plugin called "fat-jar" which would build one big jar. In Netbeans this is possible with a small piece of xml config in the build.xml: (add at the end, before the closing project tag)

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<target name="package-for-store" depends="jar">

        <!-- Change the value of this property to be the name of your JAR,
             minus the .jar extension. It should not have spaces.
             <property name="store.jar.name" value="MyJarName"/>
        -->
        <property name="store.jar.name" value="VDSL2tool"/>


        <!-- don't edit below this line -->

        <property name="store.dir" value="store"/>
        <property name="store.jar" value="${store.dir}/${store.jar.name}.jar"/>

        <echo message="Packaging ${application.title} into a single JAR at ${store.jar}"/>

        <delete dir="${store.dir}"/>
        <mkdir dir="${store.dir}"/>

        <jar destfile="${store.dir}/temp_final.jar" filesetmanifest="skip">
            <zipgroupfileset dir="dist" includes="*.jar"/>
            <zipgroupfileset dir="dist/lib" includes="*.jar"/>

            <manifest>
                <attribute name="Main-Class" value="${main.class}"/>
            </manifest>
        </jar>

        <zip destfile="${store.jar}">
            <zipfileset src="${store.dir}/temp_final.jar"
            excludes="META-INF/*.SF, META-INF/*.DSA, META-INF/*.RSA"/>
        </zip>

        <delete file="${store.dir}/temp_final.jar"/>

    </target>


Now after your development, testing you can build a single, executable, jar file, by right mouse clicking on the build.xml file and selecting the proper target:
netbeans build single jar

Next step would be building the windows exe and mac app bundle from this executable jar.

VDSL2 modem data - 7

By qless on Tuesday 25 May 2010 17:05 - Comments (8)
Categories: Java, Programming, VDSL2, Views: 2.306

And again a new version, 1.6

network mapLaunch: here

or download:
Windows (zip)

Mac OS X(zip)

Executable JAR

VDSL2 modem data - 6

By qless on Thursday 20 May 2010 10:53 - Comments (13)
Categories: Java, Programming, VDSL2, Views: 2.858

And again a new version, 1.5

Changes:
- Copy values to clipboard button
- Network map ip error fixed
- Copy network map to clipboard button
- Save network map button

http://tweakers.net/ext/f/caupq8JwayABaEAjVKIuGyWe/full.jpg

http://tweakers.net/ext/f/cWrou8MxyuAecHuLem4Bs5lh/full.jpg

Launch: here

Chambre Du Commerce

By qless on Monday 17 May 2010 14:58 - Comments (21)
Categories: Photography, Urbex, Views: 3.569

Amazing location, and very well guarded, but I escaped unnoticed ;)

More on my site

http://www.hierzo.net/foto/cdc/tfoto01.jpg http://www.hierzo.net/foto/cdc/tfoto02.jpg

http://www.hierzo.net/foto/cdc/tfoto03.jpg http://www.hierzo.net/foto/cdc/tfoto05.jpg

http://www.hierzo.net/foto/cdc/tfoto04.jpg http://www.hierzo.net/foto/cdc/tfoto06.jpg http://www.hierzo.net/foto/cdc/tfoto07.jpg

http://www.hierzo.net/foto/cdc/tfoto08.jpg http://www.hierzo.net/foto/cdc/tfoto09.jpg

http://www.hierzo.net/foto/cdc/tfoto10.jpg http://www.hierzo.net/foto/cdc/tfoto11.jpg

VDSL2 modem data - 5

By qless on Wednesday 12 May 2010 18:16 - Comments (5)
Categories: Java, Programming, VDSL2, Views: 2.043

And a brand new version.

Changes:
- Line attenuation shown
- Number of upstream/downstream bands shown
- Moden information (memory,cpu, uptime)
- Network map

http://tweakers.net/ext/f/RUz55NMUxfWpXb4lRavvzhqz/full.jpg

http://tweakers.net/ext/f/VRjsf8MgiHoJxCFD4jvd4Lkm/full.jpg

http://tweakers.net/ext/f/2IrNkh6z3N4YWoHw0ridlweU/full.jpg

Launch: here