WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Updating tcz apps  (Read 47843 times)

Offline Tahoe

  • Newbie
  • *
  • Posts: 15
Re: Updating tcz apps
« Reply #135 on: December 29, 2009, 08:23:26 PM »
As I thought, thanks. The part I was unsure of was it's placement on the path.

Is /usr/local/bin/ a good home or one of the other path dirs preferable?

Nice script JPeters, thanks again.
People tend to make rules for others and exceptions for themselves. Well now, how about that?

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #136 on: December 29, 2009, 09:05:50 PM »
As I thought, thanks. The part I was unsure of was it's placement on the path.

Is /usr/local/bin/ a good home or one of the other path dirs preferable?

Nice script JPeters, thanks again.

/usr/local/bin is always good (it's where I'd load it if I made an "update.tcz" extension).  Personally, I place my scripts in /home/tc/.local/bin, which is included in PATH and gets backed up with my home directory.

In /home/tc/.profile:
Code: [Select]

if [ -d "$HOME/.local/bin" ] ; then
      PATH=$HOME/.local/bin:$PATH
      export PATH
      fi
« Last Edit: December 29, 2009, 09:15:07 PM by jpeters »

Offline Tahoe

  • Newbie
  • *
  • Posts: 15
Re: Updating tcz apps
« Reply #137 on: December 29, 2009, 09:29:13 PM »
OK so you're simply appending a directory to the path. That little bit you got there could be done the same by inserting this somewhere no? Had to ask because my time to learn is limited. Thanks for your time and the example.

export PATH=$PATH:/home/tc/.local/bin
People tend to make rules for others and exceptions for themselves. Well now, how about that?

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #138 on: December 29, 2009, 10:03:08 PM »
OK so you're simply appending a directory to the path. That little bit you got there could be done the same by inserting this somewhere no? Had to ask because my time to learn is limited. Thanks for your time and the example.

export PATH=$PATH:/home/tc/.local/bin

That will do it. I think it's already set up in .profile though, so it will save between boots. (I haven't checked in a while...at least it used to be).   

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #139 on: December 30, 2009, 02:03:44 AM »
update-build.sh:  Builds update.tcz extension. Run in same dir with "update" script. (e.g. "sh update-build.sh").
requires squashfs-tools-4.0.tcz

Code: [Select]
#!/bin/sh

. /etc/init.d/tc-functions
DIR="."
mkdir -p /tmp/work/usr/local/bin
sudo cp ${DIR}/update /tmp/work/usr/local/bin
sudo chown -R tc:staff /tmp/work
sudo chmod 775 /tmp/work/usr/local/bin/update
cd /tmp/work
sudo mksquashfs ./ /home/tc/update.tcz
echo "${GREEN}update.tcz is in $HOME ${NORMAL}"
sudo rm -R /tmp/work

gupdate-build.sh:  Builds gupdate.tcz extension.  Run in same dir with "gupdate" script
Code: [Select]
#!/bin/sh
. /etc/init.d/tc-functions
DIR="."
mkdir -p /tmp/work/usr/local/bin
mkdir  /tmp/work/usr/local/tce.menu
sudo cp ${DIR}/gupdate /tmp/work/usr/local/bin
cat <<EOF> "/tmp/work/usr/local/tce.menu/gupdate"
<JWM>
<Program label="gupdate">/usr/local/bin/gupdate</Program>
<JWM>
EOF
sudo chown -R tc:staff /tmp/work
sudo chown -R root:staff /tmp/work/usr/local/tce.*
sudo chmod 775 /tmp/work/usr/local/bin/gupdate
sudo chmod 775 /tmp/work/usr/local/tce.*
sudo chmod 644 /tmp/work/usr/local/tce.menu/gupdate
cd /tmp/work
sudo mksquashfs ./ /home/tc/gupdate.tcz
echo "${GREEN}gupdate.tcz is in $HOME ${NORMAL}"
sudo rm -R /tmp/work
« Last Edit: December 30, 2009, 07:42:05 PM by jpeters »

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #140 on: December 30, 2009, 11:40:23 AM »
Version 4.2.1
Automatically loads its own deps if not present. (links,wget,dialog,diffutils).
For tcl_tk (dep for gupdate), uncomment it out in load() section   (lines 49,56)

Tutorial:
[removed due to policy]
« Last Edit: December 31, 2009, 05:23:15 AM by jpeters »

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #141 on: December 31, 2009, 05:22:43 AM »
Version 4.2.1
bug fix in -rem & -remop: discriminate underscored file names

Offline jpeters

  • Restricted
  • Hero Member
  • *****
  • Posts: 1017
Re: Updating tcz apps
« Reply #142 on: January 03, 2010, 01:49:30 AM »
Version 4.2.1
Automatically loads its own deps if not present. (links,wget,dialog,diffutils).
For tcl_tk (dep for gupdate), uncomment it out in load() section   (lines 49,56)

Tutorial:
[removed due to policy]

What new sick policy forbids a link to a tutorial?