user-startup won't execute commands correctly
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    Cego
    Posts: 733 from 2006/5/28
    From: Germany
    I have put "alias yt s:yt-search" into user-startup, but after rebooting it won't recognize "yt" in the command line. I have to reenter the alias command to make it work.

    I do have a similar problem with assign. I have created SYS:REXX/ as a new folder and tried to assign it to REXX: (which is by default already on S:)

    Using the assign command by itself "assign rexx: sys:rexx add" won't work. I have to completely remove the REXX: assign from the system and assign it again to S: and REXX: like this:

    assign rexx: remove
    assign rexx: sys:s
    assign rexx: sys:rexx add

    Any ideas why this is happening?

    [ Edited by Cego 17.04.2024 - 12:26 ]
    Pegasos II G4 @1.0GHz, 1GB DDR Ram, Radeon 9200Pro, 240GB SSD+160GB HD, MorphOS 3.18, AmigaOS4.1 FE, Debian 8
  • »17.04.24 - 11:11
    Profile
  • Just looking around
    jarokuczi
    Posts: 19 from 2016/12/6
    Not sure about MorphOS but in AmigaOS aliases should be added to s:shell-startup
  • »17.04.24 - 11:21
    Profile
  • MorphOS Developer
    Piru
    Posts: 587 from 2003/2/24
    From: finland, the l...
    @Cego

    1. Settings that should apply to all new shells (prompt, local variable settings, aliases) should go to S:shell-startup. To create one you can copy MOSSYS:s/shell-startup to S: and then modify S:shell-startup with the things you need.

    2. The REXX: assign is a "defer"red type. This type of assign can't be added to, until the assign has been resolved. "dir rexx: >nil:" will do that, after which you can assign add to it. Or you can do what you did (remove, add both entries).


    PS. Deferred assigns working like this was bit of a surprise to me. I would have expected "assign add" to resolve the assign and then add instead of erroring out. I might look into making Assign command do this. While this technically would be breaking compatibility with the original Commodore assign command, I think it might actually be desirable.

    [ Edited by Piru 17.04.2024 - 19:30 ]
  • »17.04.24 - 16:25
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    Cego
    Posts: 733 from 2006/5/28
    From: Germany
    Thanks! Copying and modifying shell-startup did the trick
    Pegasos II G4 @1.0GHz, 1GB DDR Ram, Radeon 9200Pro, 240GB SSD+160GB HD, MorphOS 3.18, AmigaOS4.1 FE, Debian 8
  • »17.04.24 - 16:35
    Profile