Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (6) </ 1 2 3 4 [5] 6 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: .dsl file editing utilities, a little automation never hurts< Next Oldest | Next Newest >
softgun Offline





Group: Members
Posts: 120
Joined: Dec. 2004
Posted: Mar. 03 2005,08:15 QUOTE

Quote (clivesay @ Oct. 03 2004,20:17)
I like to spend my time finding ways to automate redundant tasks.  :)

If you like to edit and repackage .dsl/.tar.gz files like I do, you probably have Ke4nt's howto doc printed out and laying in a high visibility area of your desk.

I love using emelfm and created a few shortcut buttons to speed up this task. I thought I would share with everyone. You can add these as buttons or, as I did, add them to the User Commands section of the emelfm menu.

Name: Unpack .dsl
Command: tar -zxvf %f

Name: View .dsl Contents
Command: tar -ztf %f > dirlist.txt

Name: Repack .dsl
Command: tar -T dirlist.txt --no-recursion --numeric-owner -cvf- | gzip > %{}

Thanks to clacker for educating me on how to create the last command. It will prompt you to enter the name of your new tar.gz/.dsl.

Have fun!

Chris

After unpacking nd viewing the file how do i exactly change things (using what tool) before repackaging it? Suppose i want to add a whole directory with subdirectories to the dsl befor repacking it?

Thanks for any clarification/help
Back to top
Profile PM 
reidar Offline





Group: Members
Posts: 92
Joined: Sep. 2004
Posted: Mar. 04 2005,08:55 QUOTE

Today is a joyful day for me! I finally decided to take a dive plunge into the world of .dsl-creation, based on the cheatsheet presented by Chris in this thread. The result is that I am now the proud creator of my own textmaker.dsl. (Since I have bought a licence of textmaker, I cannot share this, but I wanted to find out if I could create a .dsl from apps that I use daily and that DSL doesn't have, and Textmaker was a good starting point...)

I installed the program in the home directory, created a WORK/ directory there and put the entire textmaker/ folder there. Created an opt/ folder inside of this /home/dsl/WORK directory and moved the entire textmaker/ folder into that one. I also made a tmp/mydsl.menu folder where I put a file that I thought would give me a mydsl-menu entry (based on the investigation of a couple of other dsls). I also created a /home/dsl/.softmaker folder inside of WORK (textmaker creates such a folder, and it contains the registation-info etc.). In the end I deleted unneccesary language files from the textmaker directory, did a tar cvfz textmaker.dsl *, and I was done. Everything worked like a charm, except for one little thing: there wasn't created a mydsl-meny entry for Textmaker. Anyone knows why? I put a textmaker file inside of tmp/mydsl.menu that looked like this:

[exec] (Textmaker) {/opt/textmaker/tml}

But it didn't create a meny entry....

Everything else worked out fine though, and I am the proud owner of the textmaker.dsl file, which makes a killer wordprocessor on my old machine!

-r
Back to top
Profile PM 
clivesay Offline





Group: Guests
Posts: 935
Joined: Dec. 2003
Posted: Mar. 04 2005,13:06 QUOTE

Quote (reidar @ Mar. 04 2005,02:55)
Today is a joyful day for me! I finally decided to take a dive plunge into the world of .dsl-creation, based on the cheatsheet presented by Chris in this thread. The result is that I am now the proud creator of my own textmaker.dsl.

Congrats!

As far as your menu, you may have done something I have done myself. In the menu file, you have to enter the path as you have done and then hit the enter key to return to the next line before saving.

Also, although your .dsl my be working, I suspect it isn't 'clean' since you used the cvfz command only. Ke4nt had a great primer on .dsl creation in the forum. I am not sure exactly where. It was quite awhile back.

He taught us an important lesson you want to make sure you understand. It involved avoiding changing permissions on existing directories.

Run the tar ztf command to create a text file of the contents of your .dsl file. Open the file and look inside. You want to eliminate any lines that contain existing directory paths in the base filesystem.

/usr/bin/                 <-----Bad
/usr/bin/textmaker    <-----Good

/usr/bin already exists in the filesystem so no need to have it in your .dsl. However, /usr/bin/textmaker is new to the FS so you want to keep it.

After you have removed the offending lines, use the tar -T command to repackage your .dsl.

Now you have a nice clean file ready to submit to the community if you like!

Chris
Back to top
Profile PM MSN YIM 
reidar Offline





Group: Members
Posts: 92
Joined: Sep. 2004
Posted: Mar. 04 2005,14:07 QUOTE

Thanks a lot Chris! Your tip about my menu-problem was excellent. I did what you said (pressed Enter), went over the process of creating the .dsl again, tar -ztf, removed "dangerous" entries like tmp/, opt/ etc., used your repacking-script in emelfm and got a new clean (I believe) and perfectly workable textmaker.dsl. I also did the same for planmaker, so now I have them both. I would like to share them, but I am not sure if that is allowed, since Textmaker and Planmaker are commercial products for which I have paid? Do you know? If it is ok I will submit them of course! planmaker.dsl is 3.85 megs and textmaker.dsl is 8.13 megs. (The latter includes Norwegian dictionary, so I suppose it could be made somewhat smaller.) They are both excellent in speed and features in my opinion, especially on older machines, like the ones I use :-)

Again, this is a happy day, and it has become even more happy!!!

-r
Back to top
Profile PM 
clivesay Offline





Group: Guests
Posts: 935
Joined: Dec. 2003
Posted: Mar. 04 2005,14:35 QUOTE

I imagine those apps are not free to share. I just meant for any other apps you may put together. I have made that same menu error before and needed ke4nt to whack me upside the head to get me to see what I had done wrong.

It's great to have another extension builder amongst us.

Chris
Back to top
Profile PM MSN YIM 
27 replies since Oct. 04 2004,00:17 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (6) </ 1 2 3 4 [5] 6 >/
reply to topic new topic new poll
Quick Reply: .dsl file editing utilities

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code