Results 1 to 7 of 7

Thread: Setting current directory when making desktop launcher

  1. #1
    Join Date
    Oct 2007
    Beans
    40

    Setting current directory when making desktop launcher

    I want to make a desktop launcher for Alien Arena. From the terminal I need to go:

    cd /home/garry/Alien_Arena
    ./crx

    How do i set current directory in desktop launchers coz using a direct path like /home/garry/Alien_Arena/crx does not work. Thx

  2. #2
    Join Date
    Oct 2007
    Beans
    207
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Setting current directory when making desktop launcher

    Hi

    I had this issue with some games, so I now create a text file that contains the commands I would normally run in the terminal - Make the text file executable and then change the icon to the game icon.

    Works well for me

    Hope that helps
    Intel E8400 - 4gb Corsair DDR2-6400 - 4.5tb combined diskspace - Nvidia 9600T 1024mb - Samsung 22" WS & Eizo 19" (Twinview 2960x1050)
    The Shrooms | The Laughing Wolf | Amarok 1.4 in Jaunty | Still praying for MediaMonkey Linux

  3. #3
    Join Date
    Feb 2008
    Location
    Pittsburgh PA
    Beans
    90
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Setting current directory when making desktop launcher

    Wow read that three times. My closest guess is your trying to add a directory to your path. Like /usr/bin.
    look at your path with
    Code:
    echo $PATH
    add to your path with
    Code:
    PATH=$PATH:/new/dir/you/want/to/add
    and add export code to your .profile file
    Code:
    vi ~/.profile
    add to end of file
    Code:
    export PATH=$PATH:/new/dir
    variable in bash, one thats kinda kewl
    Code:
    PS1="variable$ "
    don't export that last one in your profile though

  4. #4
    Join Date
    Oct 2005
    Location
    Adelaide, South Australia
    Beans
    746
    Distro
    Ubuntu 11.10 Oneiric Ocelot

    Re: Setting current directory when making desktop launcher

    Ronald,

    you should suggest people use gedit to edit text files.

    most of the time the are presented with vi or nano they have no idea how to do the basic things.

    original poster also doesn't need to do any of the things you listed.

    all thats required is to make a shell script (an executable text file) that lives in the games folder.
    But purelonewolf already mentioned this.
    Fear is the mindkiller....
    The little death that obliterates...

  5. #5
    Join Date
    Oct 2007
    Beans
    40

    Re: Setting current directory when making desktop launcher

    PureLoneWolf, bloody useful trick u have, thanks alot, works a treat

  6. #6
    Join Date
    Mar 2013
    Beans
    29

    Re: Setting current directory when making desktop launcher

    @ Purelonewolf - Thank you! Thank you! This was the easiest way I found to make a shortcut to launch the game.

  7. #7
    Join Date
    Feb 2008
    Location
    Texas
    Beans
    14,704
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Setting current directory when making desktop launcher

    Thread closed. Please do not post in old threads.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •