WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Change scripts inside directory  (Read 769 times)

Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Change scripts inside directory
« on: July 22, 2019, 05:50:52 PM »
Hello, I am new to Tiny Core, thanks to my boss and his Idea to drop Debian for something that is easy.

Here is my problem:

I need to push a script inside applications.gz (gzip) that contains an image called applications (cpio) with folders inside and at another archive called jwm_config.tcz that contains the script I want to modify .jwrc

Now I am trying to use debian to access the image and I get lost because I can extract and uncompress everything, but I have no Idea how to rebuild this huge mess.

Thank you

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 6699
Re: Change scripts inside directory
« Reply #1 on: July 22, 2019, 06:20:28 PM »
Hi gotokrikkit
For the  .tcz  you need  squashfs-tools. To unpack it:
Code: [Select]
unsquashfs jwm_config.tczThe unsquashed package will be under a directory called  squashfs-root.  Make your changes, then squash it like this:
Quote
mksquashfs squashfs-root jwm_config.tcz

Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Re: Change scripts inside directory
« Reply #2 on: July 22, 2019, 07:03:42 PM »
Hi, thank you for the reply :D

The mksquashfs command works fine, the problem comes after when I try to move the file back inside the cpio. I don't know how to rebuild it or at least how to mount it in rw mode.

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 6699
Re: Change scripts inside directory
« Reply #3 on: July 22, 2019, 07:29:48 PM »
Hi gotokrikkit
You might want to check the Wiki. This might contain enough information:
http://wiki.tinycorelinux.net/wiki:remastering

Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Re: Change scripts inside directory
« Reply #4 on: July 22, 2019, 10:33:31 PM »
Tried but at the end I get
" Could not find ramdisk image: /boot/core.gz"


Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Re: Change scripts inside directory
« Reply #5 on: July 24, 2019, 05:12:23 PM »
Well guess this is another classified "great" idea from my boss ehehe

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 6699
Re: Change scripts inside directory
« Reply #6 on: July 24, 2019, 05:29:58 PM »
Hi gotokrikkit
Tried but at the end I get
" Could not find ramdisk image: /boot/core.gz"
The link I provided was to serve as an example of the syntax of the commands. You're trying to unpack/repack something called
applications.gz,  not remaster an ISO.

Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Re: Change scripts inside directory
« Reply #7 on: July 24, 2019, 05:37:41 PM »
Hey no I tried to repack the core.gz after some changes, just to get comfortable to the procedure. Unfortunately after following the instructions the core.gz was not recognized (althought it was there) at boot

Online Rich

  • TinyCore Moderator
  • Hero Member
  • *****
  • Posts: 6699
Re: Change scripts inside directory
« Reply #8 on: July 24, 2019, 05:47:01 PM »
Hi gotokrikkit
Maybe this provides better instructions:
http://forum.tinycorelinux.net/index.php/topic,15493.0.html

Offline gotokrikkit

  • WikiUser
  • *
  • Posts: 6
Re: Change scripts inside directory
« Reply #9 on: July 24, 2019, 08:47:18 PM »
Tried to run it but I think that it needs to be run from inside a working tinycore linux, something that at the moment I cannot do because I need to modify the core before installing it.

Online coreplayer2

  • Hero Member
  • *****
  • Posts: 3015
Re: Change scripts inside directory
« Reply #10 on: July 24, 2019, 11:47:35 PM »
Tried to run it but I think that it needs to be run from inside a working tinycore linux, something that at the moment I cannot do because I need to modify the core before installing it.
Surely you can boot core on a PC, or virtual machine??


Sent from my iPhone using Tapatalk