[tode_st] Could `ls` show the "type" of the nodes (when known)?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[tode_st] Could `ls` show the "type" of the nodes (when known)?

Mariano Martinez Peck
Dale, 

I think it would be very nice if `ls` could show the type of each node. For example, I wanted to create a tODE script. I tried `man touch` and none of the types was a "tODE script" so I was not exactly sure which one should I use.  Then I thought... let's see what type it has one of the tODE scripts I know. So I did `ls /sys/default/client/tode-scripts/ `. But `ls` does not show the type.... Ok it shows colors, but I don't think that's enough.

Thoughts?

Thanks! 

ps: which type should I use for `touch` to produce tODE scripts like `installServerTode` and friends?

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [tode_st] Could `ls` show the "type" of the nodes (when known)?

Dale Henrichs-3
Yeah, this is something that I've planned ... all of the object nodes listed by ls have a creation date and modification date, so we could display some interesting information ...


The original ls was  written before I supported posix options on tODE commands and after implementing posix optsion I've been meaning to circle back around and add options to all of the old commands ..

re `touch` does `man touch` help or is that too obscure as well?

`touch tpz xxx` is the command for creating a "topaz script"...

Dale

On 10/29/2015 11:15 AM, Mariano Martinez Peck wrote:
Dale, 

I think it would be very nice if `ls` could show the type of each node. For example, I wanted to create a tODE script. I tried `man touch` and none of the types was a "tODE script" so I was not exactly sure which one should I use.  Then I thought... let's see what type it has one of the tODE scripts I know. So I did `ls /sys/default/client/tode-scripts/ `. But `ls` does not show the type.... Ok it shows colors, but I don't think that's enough.

Thoughts?

Thanks! 

ps: which type should I use for `touch` to produce tODE scripts like `installServerTode` and friends?

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [tode_st] Could `ls` show the "type" of the nodes (when known)?

Mariano Martinez Peck


On Wed, Nov 4, 2015 at 3:25 PM, Dale Henrichs <[hidden email]> wrote:
Yeah, this is something that I've planned ... all of the object nodes listed by ls have a creation date and modification date, so we could display some interesting information ...


The original ls was  written before I supported posix options on tODE commands and after implementing posix optsion I've been meaning to circle back around and add options to all of the old commands ..

re `touch` does `man touch` help or is that too obscure as well?


It does help. However, it does not help to know the "type" (like those listed in `man touch`) of the already existing files. 
 
`touch tpz xxx` is the command for creating a "topaz script"...


With that sentence you mean that `installServerTode ` and friends (rebuildSys , setUpSys, loadServerTode2, etc.. ) are considered "topaz scripts" ??? mmmmm
 
 
Dale


On 10/29/2015 11:15 AM, Mariano Martinez Peck wrote:
Dale, 

I think it would be very nice if `ls` could show the type of each node. For example, I wanted to create a tODE script. I tried `man touch` and none of the types was a "tODE script" so I was not exactly sure which one should I use.  Then I thought... let's see what type it has one of the tODE scripts I know. So I did `ls /sys/default/client/tode-scripts/ `. But `ls` does not show the type.... Ok it shows colors, but I don't think that's enough.

Thoughts?

Thanks! 

ps: which type should I use for `touch` to produce tODE scripts like `installServerTode` and friends?

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.



--

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [tode_st] Could `ls` show the "type" of the nodes (when known)?

Dale Henrichs-3


On 11/04/2015 11:26 AM, Mariano Martinez Peck wrote:


On Wed, Nov 4, 2015 at 3:25 PM, Dale Henrichs <[hidden email]> wrote:
Yeah, this is something that I've planned ... all of the object nodes listed by ls have a creation date and modification date, so we could display some interesting information ...


The original ls was  written before I supported posix options on tODE commands and after implementing posix optsion I've been meaning to circle back around and add options to all of the old commands ..

re `touch` does `man touch` help or is that too obscure as well?


It does help. However, it does not help to know the "type" (like those listed in `man touch`) of the already existing files.
Yeah and that's the piece that will be added when we improve the `ls` command --- adding a `-l` option.
 
`touch tpz xxx` is the command for creating a "topaz script"...


With that sentence you mean that `installServerTode ` and friends (rebuildSys , setUpSys, loadServerTode2, etc.. ) are considered "topaz scripts" ??? mmmmm

Almost but not quite ... those  "scripts" are handled by the client and are passed into the command line machinery without interpretation in other words they are not executable .... when you create a node with `touch tpz xxx` you create an object that is by definition executable at the command line ... from the tODE shell, if you cd'ed the installServerTode directory and tried to execute one of those files you'd get an error:

  tode 1 > cd /sys/default/client/tode-scripts/
  [183455489 sz:6 TDFileSystemDirectoryNode] /sys/default/client/tode-scripts/
  tode 1 > ls
  loadServerTode  loadServerTode2  README.md  rebuildServerTode  rebuildSys  setUpSys  updateServerTode
  tode 1 > ./rebuildSys
  Topez ERROR: a TodeCommandError occurred (error 121000), Cannot execute a leaf node
  tode 1 >

because they are plain files and not executable ... it does make me think that I could create a command (`exec /sys/default/client/tode-scripts/rebuildSys`) that would allow you to execute tODE commands from a plain file ... It would  basically do what the `script` builtin does:

  script --script=rebuildSys

without the lookup bells and whistles and without being a client side builtin.

Dale

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [tode_st] Could `ls` show the "type" of the nodes (when known)?

Mariano Martinez Peck


On Wed, Nov 4, 2015 at 6:04 PM, Dale Henrichs <[hidden email]> wrote:


On 11/04/2015 11:26 AM, Mariano Martinez Peck wrote:


On Wed, Nov 4, 2015 at 3:25 PM, Dale Henrichs <[hidden email]> wrote:
Yeah, this is something that I've planned ... all of the object nodes listed by ls have a creation date and modification date, so we could display some interesting information ...


The original ls was  written before I supported posix options on tODE commands and after implementing posix optsion I've been meaning to circle back around and add options to all of the old commands ..

re `touch` does `man touch` help or is that too obscure as well?


It does help. However, it does not help to know the "type" (like those listed in `man touch`) of the already existing files.
Yeah and that's the piece that will be added when we improve the `ls` command --- adding a `-l` option.
 
`touch tpz xxx` is the command for creating a "topaz script"...


With that sentence you mean that `installServerTode ` and friends (rebuildSys , setUpSys, loadServerTode2, etc.. ) are considered "topaz scripts" ??? mmmmm

Almost but not quite ... those  "scripts" are handled by the client and are passed into the command line machinery without interpretation in other words they are not executable .... when you create a node with `touch tpz xxx` you create an object that is by definition executable at the command line ... from the tODE shell, if you cd'ed the installServerTode directory and tried to execute one of those files you'd get an error:

  tode 1 > cd /sys/default/client/tode-scripts/
  [183455489 sz:6 TDFileSystemDirectoryNode] /sys/default/client/tode-scripts/
  tode 1 > ls
  loadServerTode  loadServerTode2  README.md  rebuildServerTode  rebuildSys  setUpSys  updateServerTode
  tode 1 > ./rebuildSys
  Topez ERROR: a TodeCommandError occurred (error 121000), Cannot execute a leaf node
  tode 1 >

because they are plain files and not executable ... it does make me think that I could create a command (`exec /sys/default/client/tode-scripts/rebuildSys`) that would allow you to execute tODE commands from a plain file ... It would  basically do what the `script` builtin does:

  script --script=rebuildSys

without the lookup bells and whistles and without being a client side builtin.


And what if you consider those as "tODE scripts"  (touch tode  rebuildSys) and make them executable. And the execution will actually do "script --script=rebuildSys" 

?


--

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: [tode_st] Could `ls` show the "type" of the nodes (when known)?

Dale Henrichs-3


On 11/05/2015 09:55 AM, Mariano Martinez Peck wrote:


On Wed, Nov 4, 2015 at 6:04 PM, Dale Henrichs <[hidden email]> wrote:


On 11/04/2015 11:26 AM, Mariano Martinez Peck wrote:


On Wed, Nov 4, 2015 at 3:25 PM, Dale Henrichs <[hidden email]> wrote:
Yeah, this is something that I've planned ... all of the object nodes listed by ls have a creation date and modification date, so we could display some interesting information ...


The original ls was  written before I supported posix options on tODE commands and after implementing posix optsion I've been meaning to circle back around and add options to all of the old commands ..

re `touch` does `man touch` help or is that too obscure as well?


It does help. However, it does not help to know the "type" (like those listed in `man touch`) of the already existing files.
Yeah and that's the piece that will be added when we improve the `ls` command --- adding a `-l` option.
 
`touch tpz xxx` is the command for creating a "topaz script"...


With that sentence you mean that `installServerTode ` and friends (rebuildSys , setUpSys, loadServerTode2, etc.. ) are considered "topaz scripts" ??? mmmmm

Almost but not quite ... those  "scripts" are handled by the client and are passed into the command line machinery without interpretation in other words they are not executable .... when you create a node with `touch tpz xxx` you create an object that is by definition executable at the command line ... from the tODE shell, if you cd'ed the installServerTode directory and tried to execute one of those files you'd get an error:

  tode 1 > cd /sys/default/client/tode-scripts/
  [183455489 sz:6 TDFileSystemDirectoryNode] /sys/default/client/tode-scripts/
  tode 1 > ls
  loadServerTode  loadServerTode2  README.md  rebuildServerTode  rebuildSys  setUpSys  updateServerTode
  tode 1 > ./rebuildSys
  Topez ERROR: a TodeCommandError occurred (error 121000), Cannot execute a leaf node
  tode 1 >

because they are plain files and not executable ... it does make me think that I could create a command (`exec /sys/default/client/tode-scripts/rebuildSys`) that would allow you to execute tODE commands from a plain file ... It would  basically do what the `script` builtin does:

  script --script=rebuildSys

without the lookup bells and whistles and without being a client side builtin.


And what if you consider those as "tODE scripts"  (touch tode  rebuildSys) and make them executable. And the execution will actually do "script --script=rebuildSys" 


I'm not quite sure what you are getting at here ... the scripts that are launched by the script builtIn actually reside on the client machine's disk ... normal tode scripts are going to live in the object space of the image or on  the server machine's disk ... the reason for this is that some commands need to be run before tODE is functional - the setupSys and rebuildSys scripts are needed to make sure that the tode instance in the image is set up correctly to access the disk associated with that image/stone ... the assumption when running those scripts is that tODE may not be able to find any scripts on disk until AFTER those commands are run ...

Dale

--
You received this message because you are subscribed to the Google Groups "tODE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.