Create windows start item only for users who are not administrators

Comments

3 comments

  • Avatar
    BitRock support

    Hi,

    You can use the installer_is_root_install variable to check if the installer is run with Administrator priviledges.

    <createShortcuts>
        <destination>${windows_folder_startup}/</destination>
        <shortcutList>
            <shortcut>
                  ...          
    </shortcut> </shortcutList>
    <ruleList>
    <isFalse value="${installer_is_root_install}"/>
    </ruleList> </createShortcuts>

    Regards,

    Michiel

    0
    Comment actions Permalink
  • Avatar
    George Weis

    Hi michiel:

      That is not quite what we had in mind.  I find myself increasingly wishing I could something like this:

    a.)  Get a list of users on the windows machine we are installing on.

    b.) For those users who are not members of the Administrators group do this, otherwise do that.

     

    So, for example, suppose I had a windows 10 machine with the following log on users:

    Bob, Fred, John

    Bob and Fred are members of the Administrators group.  John is not.

     

    What I want to do during installation is to say:

    Don't do this action for Bob and Fred because they are members of the Administrators group.  But do do it for John because he is not.

    I'm sure there is a good way to do this in BitRock, I just can't see how.

    Hope this makes sense.

    Regards,

     

    George

    0
    Comment actions Permalink
  • Avatar
    BitRock support

    Hi George,

    You can use <userTest> to check if a user is admin. But for that you would need to provide the users manually. A way to do that would be using a vbs script:

    https://community.spiceworks.com/scripts/show/12-list-local-user-accounts

    Regards,

    Michiel

    0
    Comment actions Permalink

Please sign in to leave a comment.