Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Tue 21 Oct 2014, 22:28
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
Question about Shell Script (#!/bin/sh)
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 5 of 5 Posts_count   Goto page: Previous 1, 2, 3, 4, 5
Author Message
RSH


Joined: 05 Sep 2011
Posts: 2420
Location: Germany

PostPosted: Thu 19 Jan 2012, 05:00    Post_subject:  

Quote:
Here's a version using gtkdialog checkboxes:

Yes, and this one works out of the box (something is wrong with 4.1?)

I did not have a look into the 5.0 script yet, but i must say:

Idea Great Work! Idea

Exclamation Fantastic! Exclamation

_________________
LazY Puppy
RSH's DNA
SARA B.
Back to top
View user's profile Send_private_message 
jpeps

Joined: 31 May 2008
Posts: 3220

PostPosted: Thu 19 Jan 2012, 05:24    Post_subject:  

RSH wrote:
Quote:
Here's a version using gtkdialog checkboxes:

Yes, and this one works out of the box (something is wrong with 4.1?)


Works on my end. If you hack the script, all bets are off.
Back to top
View user's profile Send_private_message 
RSH


Joined: 05 Sep 2011
Posts: 2420
Location: Germany

PostPosted: Thu 19 Jan 2012, 05:53    Post_subject:  

jpeps wrote:
Works on my end. If you hack the script, all bets are off.

Yes, by having a look into previous scripts, i meant to know this already.

However: great work, again.

Maybe you can go to the GtkDialog Development Section agin, post your .pet or script and point out that it is necessary to get this one - with a handle like the tree-item is handled (to get easily out the selected items just like the tree-item gives it to the programmer).

This would be a nice and useful GtkDialog-Feature...

Edit: maybe calling it CheckboxTree.

_________________
LazY Puppy
RSH's DNA
SARA B.
Back to top
View user's profile Send_private_message 
RSH


Joined: 05 Sep 2011
Posts: 2420
Location: Germany

PostPosted: Sun 22 Jan 2012, 08:54    Post_subject:  

Code:
   #echo -e "$(Xdialog --title "$WTITLE $WMTUSER" --stdout --no-cancel --editbox /tmp/applist_tmp  16 50)" >/usr/share/applications-desktop-files/$SPATH/applist-new
   EdNewList="$(Xdialog --title "$WTITLE $WMTUSER" --stdout --no-cancel --editbox /tmp/applist_tmp  16 50)"
   #echo -e $EdNewList >/usr/share/applications-desktop-files/$SPATH/applist-new
   
   # remove old list
   if [ "$EdNewList" != "" ]; then
      rm /usr/share/applications-desktop-files/$SPATH/applist
   fi
   
   # put into file
   for i in $EdNewList
   do
      if [ "$EdNewList" != "" ]; then
         echo -e $i >> /usr/share/applications-desktop-files/$SPATH/applist
      fi
   done


This will write output as single lines into a file.

f.e.:

file1
file2
file3...

Also the batch file (here=applist) will stay and will not loose it's data when closing the window (not using ok button)

Maybe good to know?

_________________
LazY Puppy
RSH's DNA
SARA B.
Back to top
View user's profile Send_private_message 
jpeps

Joined: 31 May 2008
Posts: 3220

PostPosted: Sun 22 Jan 2012, 16:17    Post_subject:  

The output from batch selection already remains in /tmp

Code:

/tmp $ cat batch-list
CPUtemp_usage-2.0
flashplayer
Back to top
View user's profile Send_private_message 
disciple

Joined: 20 May 2006
Posts: 6447
Location: Auckland, New Zealand

PostPosted: Mon 23 Jan 2012, 17:06    Post_subject:  

Could you please add your gtkdialog apps to the index of programs using gtkdialog?
Thanks.

_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send_private_message 
jpeps

Joined: 31 May 2008
Posts: 3220

PostPosted: Mon 23 Jan 2012, 22:46    Post_subject:  

disciple wrote:
Could you please add your gtkdialog apps to the index of programs using gtkdialog?
Thanks.


Wouldn't it be better to have them all in one list,vs tacked on arbitrarily as
replies in a thread somewhere?
Back to top
View user's profile Send_private_message 
disciple

Joined: 20 May 2006
Posts: 6447
Location: Auckland, New Zealand

PostPosted: Mon 23 Jan 2012, 23:09    Post_subject:  

Yeah, and categorised or at least listed alphabetically. In a way a wiki page would be better. But I figured just collecting them all in one place was a good start.
And the advantage of the forum thread is that if they want people can keep track of new ones as they are added.

_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send_private_message 
recobayu


Joined: 15 Sep 2010
Posts: 113
Location: indonesia

PostPosted: Tue 14 Aug 2012, 05:44    Post_subject: rox got hang when i go to directory /proc  

hi everyone,
i want to ask you a question.
i make a pet that can setting my rox. actually, this pet is a small part of my big .pet. i just want to make easy, because every come a new varian puppy linux, i download it, try it, and then i must setting everything i want and that is eat my time. so i make an easy pet to setting that.
then my problem was appear when i use another puppy (not lupu, in my case is dpup exprimo). after i install my pet, rox got hang if i go to directory /proc.
i have 2 files in my pet,there are:
Code:
/root/.config/rox.sourceforge.net/ROX-Filer/menus2
/root/.config/rox.sourceforge.net/ROX-Filer/Options

can anyone explain that?
thanks.
aku.pet
Description 
pet

 Download 
Filename  aku.pet 
Filesize  2.51 KB 
Downloaded  241 Time(s) 
Back to top
View user's profile Send_private_message 
stu91


Joined: 06 Aug 2012
Posts: 145
Location: England. Dpup. Dell Inspiron 1501

PostPosted: Tue 14 Aug 2012, 08:54    Post_subject: Re: rox got hang when i go to directory /proc  

recobayu wrote:
hi everyone,
i want to ask you a question.
i make a pet that can setting my rox. actually, this pet is a small part of my big .pet. i just want to make easy, because every come a new varian puppy linux, i download it, try it, and then i must setting everything i want and that is eat my time. so i make an easy pet to setting that.
then my problem was appear when i use another puppy (not lupu, in my case is dpup exprimo). after i install my pet, rox got hang if i go to directory /proc.
i have 2 files in my pet,there are:
Code:
/root/.config/rox.sourceforge.net/ROX-Filer/menus2
/root/.config/rox.sourceforge.net/ROX-Filer/Options

can anyone explain that?
thanks.


I encounted this when building D-lite puppy -
There was / maybe still is a bug i think with rox-filer that if you had thumbnail images enabled in rox options when went to /proc directory rox-filer would hang - solution was to down-grade to an earlier version of rox-filer.
Back to top
View user's profile Send_private_message 
recobayu


Joined: 15 Sep 2010
Posts: 113
Location: indonesia

PostPosted: Sun 26 May 2013, 12:18    Post_subject: a little latex and bash language  

Hi Everyone,
I want to share just a little things that i've found just now. I make a combination of bash and latex. I install latex by emil from here: (thanks emil)
http://murga-linux.com/puppy/viewtopic.php?t=61226
Then i make a script like this, just playing a small things..

Code:

#!/bin/sh
echo "\documentclass[a4paper]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{lmodern}
\usepackage[english]{babel}
\begin{document}
Hi guys, I have an exercise for you.. Can you answer this question?
">recobayu.tex
for i in {1..15};do
echo "$i.">>recobayu.tex
x1=$((RANDOM%10+1))
x2=$((RANDOM%10+1))
#x" + bx + c =0
b=-$(($x1+$x2))
c=$(($x1*$x2))
echo "$ (x-$x1)(x-$x2)=0 \Leftrightarrow x^2 $((b)) x + $c =0 $
">>recobayu.tex
done
echo "\end{document}">>recobayu.tex
pdflatex recobayu.tex recobayu.pdf
evince recobayu.pdf

That's all. Now, I have a quadratic equation exercise.
Anyone want to play around?
Very Happy
Back to top
View user's profile Send_private_message 
Display_posts:   Sort by:   
Page 5 of 5 Posts_count   Goto page: Previous 1, 2, 3, 4, 5
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » Off-Topic Area » Programming
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0795s ][ Queries: 13 (0.0071s) ][ GZIP on ]