Slaxer_Pup 4.12 solid and stable non woof build

Under development: PCMCIA, wireless, etc.
Message
Author
amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#436 Post by amigo »

Actually, the 'neatest' patches are to be had by separating the changes between bug-fix, feature, formatting and hacks -or other such 'categories'. It just means making a couple of extra inetrmediate diffs as you add in all your changes, but it keeps the code separate -especially for features/hacks. You'll be glad you did the netx time you go to apply the changes against a new version of the original tools, or whatever.
Personally, I'd just leave the functioning code for the tbz/tlz packages as it will make your patches shorter and neater. Or just comment it and leave it -when you change the number of lines drastically the diffs are harder interpret visually with xdiff or other such viewer.

I agree with the commenting/removal of the code which doesn't allow to use makepkg in the current directory -that's new lately in slack pkgtools.

I appreciate you posting your work -I was able to get an overview of what you had changed pretty easily. Oh, BTW, you have a routine there which creates a script in /var/log/setup -there's a line (~326) in /etc/rc.d/rc.S which wipes that out on every boot. Probably best to create that first when your tool runs and then remove it when finished.

I'm looking at how to integrate some of that into my pkgtools version. I'm also working making all my init routines use dash to speed boot-times. I'm using a statically-linked /bin/dash called specifically by the main rc.* files. /bin/sh is still linked to bash to avoid problems with any scripts we don't have control of.

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#437 Post by big_bass »

Hey Gilbert (amigo)


thanks for the tips !
-----------------------

here's a small script to help out with those lazy people who like drag N drop package installs :D

if you don't care to see the progress remove the -hold
from the xterm command
*you'll have to manually close the box

Code: Select all

#!/bin/sh

#code by Joe arose  big_bass  
#this is a very fast drag n drop tool
#for installing tgz packages
#it coupled with rox to get the right click 
#in the menu
#call this script install_tgz

#.tgz	  
if echo `basename "$1"` | grep -q '.tgz$'; then
   
   
Xdialog --wrap --title "YES/NO BOX" \
        --yesno "Do you want to install $1" 0 0

case $? in
  0)
    echo "Yes chosen.";;
  1)
    echo "No chosen."
    exit;;
  255)
    echo "Box closed."
    exit;;

esac
             

xterm -hold -geometry 40x30+150+40 -e installpkg "$1"         

Xdialog --title "Complete" \
        	--infobox "\nInstalling $1 has finished.\n" 0 0 3000


#get the menus updated 
/usr/sbin/fixmenus #hack for JWM and ICEWM  
jwm -restart       #hack for JWM and ICEWM  Joe Arose aka big_bass 


else
 Xdialog --title "not a tgz " \
        	--infobox "\ntgz only.\n" 0 0 4000


fi


big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#438 Post by big_bass »

Hey Gilbert (amigo)
Actually, the 'neatest' patches are to be had by separating the changes between bug-fix, feature, formatting and hacks -or other such 'categories'. It just means making a couple of extra inetrmediate diffs as you add in all your changes, but it keeps the code separate -especially for features/hacks. You'll be glad you did the netx time you go to apply the changes against a new version of the original tools, or whatever.
well ,I agree and offer the neatest solution
I wish I had something like this when I started trying to figure out
pkgtools !

I made these as all in one scripts that can be run stand alone
the code is cleaner and works and shows what is happening
with a few more comments so I don't forget either
I found another way the EOF is cleaner than the echoing


these scripts are just for demonstrating the code in parts
if you installed my packagetoolsx they are already included

Code: Select all


#!/bin/sh

# this allows you to run the official package tools without editing 
# any files used by it so its safe to use this New GUI at any time
# The new files will be made and used 
# by Joe Arose 2-17-2010

# list_of_installed_packages2   located in /var/log/setup/tmp
# xpackage_viewer               located in /var/log/setup/tmp
# viewsrc2                      located in /var/log/setup/tmp

# list_of_installed_packages2   needs a new list generated for xdialog to work 
# xpackage_viewer               is the main viewer for the all package list view   
# viewsrc2                      this shows the individual selected package

# xpackage_viewer               is auto generated from this script
# viewsrc2                      is auto generated from this script  

# this replaces the dialog version for xdialog            
# a problem was dialog uses a --file option that is done differently with xdialog
# so  adjustments to the formating of how the PACKAGE DESCRIPTION:
# was parsed generates a valid xdialog list now
# then a new script replaced viewsrc with xpackage_view + viewsrc2
# I split it into subroutines 



#  there are 4 parts needed 
#  part 1 is generate list_of_installed_packages2 
#  part 2 is the xpackage_viewer
#  part 3 is run by viewsrc2 automatically
#  part 4  is reading the package selected reply2
#          and piping that into Xdialog 




#----------------------------------------
# generate list_of_installed_packages2 
#----------------------------------------

    	FILES=$(ls /var/log/packages)
        cd /var/log/packages
      { grep '^PACKAGE DESCRIPTION:$' -Z -H -m1 -A1 $FILES; echo; } \
      | sed -n 'h;n;/\x00/{h;n;};x;s/  */ /g;s/ $//;s/[\"`$]/\\&/g
       s/\(.*\)\x00\([^:]*:\)\? *\(.*\)/ "\1"    "" OFF \\/;p' > /var/log/setup/tmp/list_of_installed_packages2 
touch  /var/log/setup/tmp/list_of_installed_packages2 
     


#----------------------------------------
# generate viewsrc2
#----------------------------------------

cat << 'EOF' >/var/log/setup/tmp/viewsrc2
#!/bin/sh

#make the package selected to view a string value called RETURN2
RETURN2=`cat /var/log/setup/tmp/return2`

#then pipe that into xdialog 

echo "`cat /var/log/packages/$RETURN2`" | Xdialog --title " $RETURN2    files " \--backtitle " $RETURN2   list   "     \--textbox "-" 30 70 0
EOF

chmod a+x /var/log/setup/tmp/viewsrc2




#----------------------------------------
# generate /var/log/setup/tmp/xpackage_viewer
#----------------------------------------
# this makes a script using echo 
# with the new formated PACKAGE DESCRIPTION:

# make the xdialog head 

cat << 'EOF' >/var/log/setup/tmp/xpackage_viewer
#!/bin/sh
Xdialog --title " Package you wish to view more info"\
--backtitle "Installed packages info  "     \
--radiolist "Select a package you want to view       \
                                             \n"  35 50 2  \
EOF
                                             
# build the list of installed packages                                     
# this the body of the script 

echo "`cat /var/log/setup/tmp/list_of_installed_packages2`">>/var/log/setup/tmp/xpackage_viewer 

# the chosen value is used to view just that file from the main list 

cat << 'EOF' >>/var/log/setup/tmp/xpackage_viewer
2> /var/log/setup/tmp/return2 


case $? in
  0)
    echo "Yes chosen.";;
  1)
    echo "No chosen."
    exit;;
  255)
    echo "Box closed."
    exit;;

esac 

/var/log/setup/tmp/viewsrc2
EOF


# make it executable
chmod a+x /var/log/setup/tmp/xpackage_viewer 

#----------------------------------------
# run the new "viewscr2" 
# automatically from /var/log/setup/tmp/xpackage_viewer
#----------------------------------------
 
/var/log/setup/tmp/xpackage_viewer

Code: Select all


#!/bin/sh

# this allows you to run the official package tools without editing 
# any files used by it so its safe to use this New GUI at any time
# by Joe Arose 2-17-2010


#----------------------------------------
# generate /var/log/setup/tmp/new_installer_list
#----------------------------------------

cd /
find / -name '*.tgz' -exec echo  {} \; >/var/log/setup/tmp/new_installer_list

# filter out initrd
cat var/log/setup/tmp/new_installer_list|grep -v 'initrd' >/var/log/setup/tmp/new_installer_list
     
touch  /var/log/setup/tmp/new_installer_list
      


#----------------------------------------
# generate /var/log/setup/tmp/view_all_tgz
#----------------------------------------

cat << 'EOF' >/var/log/setup/tmp/view_all_tgz
#!/bin/sh

# then stick that in your Xdialog pipe and smoke it  :D

echo "`cat /var/log/setup/tmp/new_installer_list`" | Xdialog --title "    TGZ finder " \--backtitle " All  TGZ  list   "     \--textbox "-" 30 70 0
EOF

chmod a+x /var/log/setup/tmp/view_all_tgz

. /var/log/setup/tmp/view_all_tgz





amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#439 Post by amigo »

Well, that does look a lot cleaner! I was working yesterday on ramming some of your GUI code into the regular pkgtool, in a way that the same script could be used with or without Xdialog.

pkgtool would be lots easier to work with if the code was broken up more into functions. And the shallow indenting makes it hard to read... My hacked version is formatted better, but I haven't yet broken out much code into functions. I have added lots of code for handling the extra database files, but it is mostly in one spot so it isn't too hard to work with/around. I forked my version quite some time ago -before the official tools supported tbz/tlz/txz so I handled that a little differently than they did. Once forked, the best way to check/keep up with any fixes or features from upstream is to simply make diffs against the original versions. As I said before, I'm against some of the changes, so I have no desire to take new versions and re-convert them.

You mentioned drag-n-drop package handling... I have for a long time used a rox AppDir front-end to pkgtools which is great for quickly installing or upgrading packages just by dropping them on the icon. Plus, right-clicking brings up a menu with some functions for quickly listing all installed packages, searching for a file to find out what package installed it, listing the contents of package nicely and for searching in a MANIFEST to see what package supplies a certain uninstalled file.

You can get an older version here:
http://distro.ibiblio.org/pub/linux/dis ... ls-0.2.tbz
It uses a variety of GUI (gtk-1.2) helpers which you'll want to install to see how it works. But, you might want to replace those routines with pure Xdialog or gtkdialog code.
Xdialog -I know you have this :-) Did you know there's a GTK2 version?

greq
gtk-shell
gselect:
http://distro.ibiblio.org/pub/linux/dis ... MsgDialog/

afxmsg:
http://distro.ibiblio.org/pub/linux/dis ... ts/afxmsg/

gmas:
http://distro.ibiblio.org/pub/linux/dis ... mas-1.1.0/

It could probably have all been done with just Xdialog, but i was experimenting and some of the widget tools are more attractive and easier to use than even Xdialog
You are definitely on the right track if these can be used as simple frontends to the regular tools.

Say, I've been working on init/boot functionality for my new system and have gotten down to a 6 second bootime(from grub selection to CLI login)! I'm using a statically-linked dash for running the init scripts which brought times down from ~15 seconds to 6-7. Still room to cut a couple more seconds out there...

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#440 Post by big_bass »

pkgtoolsx
UPDATED 2-23-2010

*mostly cleaning up the code so its easier to diff and read
added back tbz tlz support
http://puppy2.org/slaxer/pkgtoolsx-13.0-noarch-9.tgz



Xdialog version of packagetools (pkgtools)

so now its an X environment tool !

you should have the my pkgtools-13.0-patched-10-i486-slxr.pet
already installed its safe to have both since no files get over written

one for console one for X

Tip:if you have your packages in another directory copy the
pkgtoolx script into that folder and run it from there the
default is root

note when asked to install packages select yes ,no ,or quit

Joe

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#441 Post by big_bass »

Xinstallpkg


I have been working on updating the official slackware package management tools to include a X version
whereas slackware uses a console version tried and true

but lets give that a face lift when we are in X

while doing this I have separated each function into subroutines
also in doing it this way I have maintained not to clobber any files used by the official tools and at the same time keeping thing compatible


there are some tools I use to make my life easier one is dragNdrop
scripts to install but I use a better way when there are many packages to install and that is a new script I wrote called xinstallpkg

it doesnt use any installpkg code in the front end GUI but uses the official installpkg as the backend so as not to break any (sacred rules ) lol



you can place this script anywhere you have a folder with *tgz packages and just click a GUI opens allowing you to use check boxes
to select what you want to install

then everything from there is automatic :D

in slackware you have KDE frontend that does this type of work looks great but its big and bloated
doing it all in Xdialog makes it very very fast and light

*you have to have installpkg already installed

the trick is a making Xdialog work with dynamic
menus

Joe
Attachments
xinstaller_image.png
(25.54 KiB) Downloaded 1392 times
xinstallpkg.tar.gz
(1.3 KiB) Downloaded 647 times

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#442 Post by big_bass »

having fun coding these things
a simple but useful drag N drop diff maker using Xdialog
for comparing two files


Code: Select all

#!/bin/sh


# just a simple diff tool for the lazy
# there are better but this is easy :D 
# Joe Arose 
# call this dnd_diff
DIALOG=Xdialog

$DIALOG --title "first file for DIFF   " \
        --inputbox "Type in a value or Drag N drop.
         enter first file to diff now
        the name will be given from the this file.diff
        and placed in root\n
" 10 70 2> /tmp/one.txt

retval=$?



input=`cat /tmp/one.txt`


case $retval in
  0)
    echo "Input string is '$input'";;
  1)
    echo "Cancel pressed."
    exit;;
  255)
    echo "Box closed."
    exit;;
esac

#----------------------------------
$DIALOG --title "second file for DIFF   " \
        --inputbox "Type in a value or Drag N drop.
        you enter second file to diff now\n
" 10 70 2>/tmp/two.txt

retval=$?

input2=`cat /tmp/two.txt`

case $retval in
  0)
    echo "Input string is '$input2'";;
  1)
    echo "Cancel pressed."
    exit;;
  255)
    echo "Box closed."
    exit;;
esac

diff -pruN $input $input2 >/root/`basename $input`.diff

#or you could do this if you have another editor installed 
$DEFAULTTEXTEDITOR  /root/`basename $input`.diff

#geany is the default editor change this if you have another editor
#geany /root/`basename $input`.diff

rm -f /tmp/two.txt
rm -f /tmp/one.txt

gronos04
Posts: 54
Joined: Sun 31 Dec 2006, 00:54
Location: Radfordia QLD

#443 Post by gronos04 »

Thanks for all your work on the package installers.
I needed python version 2.4.3 to work on some idigi modules.
Downloaded the source then used src2pkg.
Then used the installer and all went well.
However I get this when I run python
# python
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python 2.4.3 (#1, Mar 1 2010, 19:56:10)
[GCC 4.1.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.

It still works but ......

Also what do you use to programme ICs with?
Tried to get the Arduino ide going but could not get avr-gcc to compile so avr-libc was no go. Got these as Slackware sources.

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#444 Post by big_bass »

gronos04

its good that your using src2pkg
python is a "python" when you need to compile
it keeps growing a hungry snake it is


but here is a later version of python I complied for slaxer if you need it
http://www.murga-linux.com/puppy/viewto ... &start=317


*depending what ic's you need to write to?

Joe

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#445 Post by big_bass »

Tried to get the Arduino ide going but could not get avr-gcc to compile so avr-libc was no go. Got these as Slackware sources.
gronos04
you need java installed

http://www.arduino.cc/en/Main/Software
http://www.arduino.cc/playground/Learning/Linux
Joe

gronos04
Posts: 54
Joined: Sun 31 Dec 2006, 00:54
Location: Radfordia QLD

#446 Post by gronos04 »

big_bass

Yes, I had installed java first.

Will go through the process again when time permits

thanks

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#447 Post by big_bass »

minor update to improve speed 3-16-2010
minor update to improve names by using only one underscore when many spaces are found 3-17-2010

this is something I wanted to do for awhile
fix spaces in directory names and files
convert them to use the underscore

many problems are caused by having spaces in file names or directory names even firefox is guilty of this bad habit !


try this one first to see what it does
two scripts here the first is dragN drop or command line call it s2u what it does is space2underscore

the second is auto find fix and repair
call it s2u_auto that does all the work for you
and may take awhile if you have a lot of bad files
--------------------------------------------------------------------




call it s2u what it does is space2underscore

Code: Select all

#!/bin/bash

# Joe Arose version 1.02  
# s2u = space2underscore  
# drag N drop rename files that have spaces placed in the name 
# to a corrected format with underscores 
# many spaces get replaced with underscores also  
# programs will not function correctly with spaces placed in the name 
# added to rox right clicks is even better than drag N drop
# this also works from command line  an example   s2u /path/name of file
# so it can clean up and correct a list of files  also 
# note that permissions are preseved !

rm -f /tmp/space2question
rm -f /tmp/space2underscore     
rm -f /tmp/fix_spaces.txt

#this is to show how many files you have spaces it the name
#this is faster 

find $pwd -type f |tr " " "?" | grep '?'>>/tmp/fix_spaces.txt




echo  "$@" | tr " " "?" >/tmp/space2question
echo  "$@" | tr -s ' ' '_*' >/tmp/space2underscore     

##special function to clean everything 
echo  "$@" |tr -d  '=;:`"<>,?!@#$%^*&(){}[]' |tr -s ' ' '_*'  >/tmp/sanitized


rename_this=`cat /tmp/space2question`


for_this=`cat /tmp/space2underscore`


mv $rename_this $for_this



 Xdialog --title "Complete" \
        	--infobox "\nConversion to $for_this has finished.\n" 0 0 2000

rm -f /tmp/space2question
rm -f /tmp/space2underscore     
 
  
 








call it s2u_auto that does all the work for you

Code: Select all

#!/bin/bash

# Joe Arose version 1.02  
# s2u_auto  = space2underscore  auto find and repair 
# rename files that have spaces placed in the name 
# to a corrected format with underscores 
# many spaces get replaced with underscores also  
# programs will not function correctly with spaces placed in the name 
# note that permissions are preseved !


rm -f /tmp/space2underscore
rm -f /tmp/space2question
rm -f /tmp/fix_spaces.txt

#this is to show how many folders you have spaces in the name
#this is faster fix directories first later it will fix the files 

find $pwd -type d |tr " " "?" | grep '?'>>/tmp/fix_spaces.txt


for pkg in `cat /tmp/fix_spaces.txt` ;do
echo "$pkg" | tr " " "?" >/tmp/space2question
echo "$pkg" | tr -s ' ' '_*' >/tmp/space2underscore  


rename_this=`cat /tmp/space2question`
for_this=`cat /tmp/space2underscore`

mv $rename_this $for_this

# just in case give it some time to process example n" 0 0 1000
# the delay here is one second 1000 =1sec

Xdialog --title "working" \
        	--infobox "\n Auto conversion  working $for_this.\n" 0 0 1000

done 


 Xdialog --title "Complete" \
        	--infobox "\n Auto conversion folders  finished.\n" 0 0 3000

#-----------------------------
#  fix all the files now
#----------------------------
rm -f /tmp/space2underscore
rm -f /tmp/space2question
rm -f /tmp/fix_spaces.txt

#this is to show how many files you have spaces in the name
#this is faster 
find $pwd -type f |tr " " "?" | grep '?'>>/tmp/fix_spaces.txt


for pkg in `cat /tmp/fix_spaces.txt` ;do
echo "$pkg"| tr " " "?" >/tmp/space2question
echo "$pkg" |tr -s ' ' '_*' >/tmp/space2underscore


rename_this=`cat /tmp/space2question`
for_this=`cat /tmp/space2underscore`

mv $rename_this $for_this

#just in case give it some time to process

Xdialog --title "working" \
        	--infobox "\n Auto conversion  working $for_this.\n" 0 0 1000

done 


 Xdialog --title "Complete" \
        	--infobox "\n Auto conversion files  finished.\n" 0 0 3000


rm -f /tmp/space2underscore
rm -f /tmp/space2question
rm -f /tmp/fix_spaces.txt










I also did a complete rewrite of a light xdialog pkgtools
for those wondering why ?
package management
is what sets down the standard of the distro the packages used
and its future development direction

@amigo I would like to add your fixes to the dependency
database checking that you worked on if you have a subroutine for it

Joe

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#448 Post by big_bass »

this is a drag N drop sanitize bad names of directories or files
one a at time will come in handy if your fixing downloaded files too

call it sana
sana = sana sana colita de rana "for the spanish translation"

**I need to run some checks of packages and files for the package tools and an indexer for html so these are some small routines I am using to filter and clean with and they come in handy as small stand alone apps

make a new file and call it this
c^%a#!?n{}_y@o]u[_?@r%e"a$d_><t=h:i*()s


now drag n drop it on the script you named sana

Code: Select all

#!/bin/bash

# Joe Arose version 1.05 

# added to rox right clicks is even better than drag N drop
# this also works from command line  an example   sana /path/name of file
# so it can clean up and correct a list of files  also 
# note that permissions are preseved !

#sanitize
#one at a time 

rm -f /tmp/tmp/sanitized
rm -f /tmp/borked_name   



##special function to clean everything 
echo  "$@" | tr -d '=;:`"<>,?!@#$%^*&(){}[]' |tr -s ' ' '_*' >/tmp/sanitized
echo  "$@" | tr " " "?" | tr  '=;:"`<>,!@#$?%^*&(){}[]' '?' >/tmp/borked_name




rename_bork=`cat /tmp/borked_name`
echo  "$rename_bork"


for_cleaned=`cat /tmp/sanitized`
echo "$for_cleaned"

mv $rename_bork $for_cleaned 



 Xdialog --title "Complete" \
        	--infobox "\nConversion to $for_cleaned has finished.\n" 0 0 2000


big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#449 Post by big_bass »

This auto detects and renames badly named files and directories
anywhere you place it


sana_auto

NOTE
# this is disabled to allow you to test first uncomment lines 44;91 when you know what will be renamed

so its safe to test as is with to see which files would be renamed if you uncommented those lines

wow ! this nice 8)

I ran this on three of my partitions without any problems
all the files were renamed correctly

I thought of another good use for this when you want to burn to CD sometimes there are problems with long mis-formatted names this will fix those types of problems

will save hours of work
a small but powerful app

take a look at this file it shows what will be renamed
/tmp/fix_borked_names.txt

theses files show what will be renamed
/tmp/fix_borked_names_dir
/tmp/fix_borked_names_files


Code: Select all

#!/bin/bash

# Joe Arose version 1.06  
# sana_auto  =  auto find and repair 
# sana =  sanitize  these =;"`<>,!@#$?%^*&(){}[]
# sana =  sana sana colita de rana   "for the spanish translation" 
# kde mime images have a ":" so leave them alone 
# to a corrected format with underscores 
# many bad characters get deleted  
# programs will not function correctly with spaces placed in the name 
# note that permissions are preseved !

# this is disabled to allow you to test first uncomment lines 44;91 when you know what will be renamed  
so its safe to test 

# if you plan to edit this comment out the "mv"  lines for safety while testing line 44 ;91

rm -f /tmp/sanitized
rm -f /tmp/borked_name
rm -f /tmp/fix_borked_names.txt


#this is faster fix directories first later it will fix the files 


find $pwd -type d | tr " " "?" | tr  '=;"`<>,!@#$?%^*&(){}[]' '?'| grep '?' >>/tmp/fix_borked_names.txt

#so you have a list of changed files that have ???
cp /tmp/fix_borked_names.txt /tmp/fix_borked_names_dir$$


##special function to clean everything 

for pkg in `cat /tmp/fix_borked_names.txt` ;do
echo "$pkg" | tr -d '=;`"<>,?!@#$%^*&(){}[]' |tr -s ' ' '_*' >/tmp/sanitized
echo "$pkg" | tr " " "?" | tr  '=;"`<>,!@#$?%^*&(){}[]' '?' >/tmp/borked_name


rename_bork=`cat /tmp/borked_name`
echo  "$rename_bork"


for_cleaned=`cat /tmp/sanitized`
echo "$for_cleaned"

#mv $rename_bork $for_cleaned 



 Xdialog --title "working on directories" \
        	--infobox "\nConversion to $for_cleaned has finished.\n" 0 0 1000

done 


 Xdialog --title "Complete" \
        	--infobox "\n Auto conversion folders  finished.\n" 0 0 3000

#-----------------------------
#  fix all the files now
#----------------------------

rm -f /tmp/sanitized
rm -f /tmp/borked_name
rm -f /tmp/fix_borked_names.txt


find $pwd -type f | tr " " "?" | tr  '=;"`<>,!@#$?%^*&(){}[]' '?'| grep '?' >>/tmp/fix_borked_names.txt


#so you have a list of changed files that have ???
cp /tmp/fix_borked_names.txt /tmp/fix_borked_names_files$$


##special function to clean everything 


for pkg in `cat /tmp/fix_borked_names.txt` ;do
echo "$pkg" | tr -d '=;`"<>,?!@#$%^*&(){}[]' |tr -s ' ' '_*' >/tmp/sanitized
echo "$pkg" | tr " " "?" | tr  '=;"`<>,!@#$?%^*&(){}[]' '?' >/tmp/borked_name





rename_bork=`cat /tmp/borked_name`
echo  "$rename_bork"


for_cleaned=`cat /tmp/sanitized`
echo "$for_cleaned"

#mv $rename_bork $for_cleaned 



 Xdialog --title "working on files" \
        	--infobox "\nConversion to $for_cleaned has finished.\n" 0 0 1000

done 


 Xdialog --title "Complete" \
        	--infobox "\n Auto conversion files  finished.\n" 0 0 3000


gronos04
Posts: 54
Joined: Sun 31 Dec 2006, 00:54
Location: Radfordia QLD

#450 Post by gronos04 »

I would like to upgrade some base apps.
I wanted to install the latests alsa 1.0.22.
src2pkg worked perfectly, compiled and gave me a .tgz package.
Used pkgtool on the package thinking that it might just overwrite it but no luck.
Could someone please outline the steps to upgrade applications that were never installed by pkgtool?
I am running slaxer_pup as a frugal install.

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#451 Post by amigo »

installpkg name-of-package.tgz will install it -ovberwriting any existing files of the same name. To upgrade use: upgradepkg name-of-package.*tgz
If you have something already installed with installpkg, trying to use installpkg will not work (with same package name).

gronos04
Posts: 54
Joined: Sun 31 Dec 2006, 00:54
Location: Radfordia QLD

#452 Post by gronos04 »

Beautiful.

Thanks very much Amigo

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

#453 Post by big_bass »

I improved the dragNdrop unzipper and it looks better with Xdialog

I also added tazpkg support for slitaz



*I have a lot of good stuff coming I just have to upload it
I wrote a whole new package manager
it took two months of work so I have been busy coding


slaxer pup is what I use everyday and it will be kept up to date
without burning a new CD with add on packages





Joe
Attachments
unzipper_dragNdrop3.tar.gz
(1.15 KiB) Downloaded 672 times

big_bass
Posts: 1740
Joined: Mon 13 Aug 2007, 12:21

xdialog package tools

#454 Post by big_bass »

download the slaxerPup_updater2



small edit 4-20-2010 updated the makepkg in pkgtools to allow building in current directory the official makepkg doesnt allow it *rust rerun the updater the package was fixed on the server



you only need to run it once
unzip it then click on it

packages will be downloaded and installed
only the pet package asks you if you want to install it

all the tgz packages are automatic

this makes slaxer_pup updated to the latest stable version



maybe you'll get why I am using slackwares format
it is a standard that all linux developers are familiar with

throwing everything into a remastered iso
will only lead to confusion and is very anti- friendly
to the open source community
thats why

slaxer pup will be built using packages so work can be shared on other linux systems




slaxer_pkg_tools

now you have a new beautiful (tgz and txz )and fast installer for the x environment




Joe
Attachments
slaxer installer image .png
(23.87 KiB) Downloaded 1377 times
slaxerPup_updater2.tar.gz
(1.25 KiB) Downloaded 651 times
Last edited by big_bass on Fri 23 Apr 2010, 02:12, edited 1 time in total.

User avatar
Nikukyu
Posts: 15
Joined: Mon 12 Oct 2009, 14:40
Location: Zipangu
Contact:

#455 Post by Nikukyu »

Hi big_bass
I'm Puppy Linux Japanese Forum Member
Nikukyu :D

I made a improvement of unpackager-dragNdrop-1-i486-slxr.pet
They were made to correspond to deb,rpm and tbz.
It tries.

Unpackager-DnD++.pet made them correspond to arj, lha, rar, and zip in addition.
However, only a simple decompression corresponds to rar.

Post Reply