Giter VIP home page Giter VIP logo

Comments (15)

 avatar commented on June 2, 2024

That is wrong solving.
In order to install devkit in ubuntu you need to comment\remove this part in install.sh script:

if [ ! -w "/usr/local" ]; then
        error "You need write permissions to /usr/local"
        echo "Try running: sudo chown -R \$USER /usr/local"
        exit 1
fi

Just comment it like this:

# if [ ! -w "/usr/local" ]; then
#       error "You need write permissions to /usr/local"
#       echo "Try running: sudo chown -R \$USER /usr/local"
#       exit 1
# fi

That's all.

from devkit.

marti1125 avatar marti1125 commented on June 2, 2024

comment these lines of code doesn't work for me.

in this case when I tried ./install.sh i get some problem with permissions

so I should be run sudo ./install.sh.

from devkit.

mikehenrty avatar mikehenrty commented on June 2, 2024

@marti1125, did you try installing node as you current user rather than root?

http://tnovelli.net/blog/blog.2011-08-27.node-npm-user-install.html

from devkit.

borfast avatar borfast commented on June 2, 2024

@mikehenrty, instead of forcing users to change their system to accommodate a specific way of working, why not make this work correctly?

I don't mean to be rude but suggesting that users should chmod /usr/local to their non-root user is irresponsible, to say the least.

from devkit.

borfast avatar borfast commented on June 2, 2024

Ah, not to mention that it doesn't solve the issue. You still have to change the install.sh script in order to make it work.

Why not make this install the necessary npm packages locally instead of globally?

from devkit.

mikehenrty avatar mikehenrty commented on June 2, 2024

@borfast Unfortunately we don't officially support the Linux platform just yet, so any advice we give for the moment are just temporary workarounds. The link I posted was from this bug, and has worked on some Ubuntu installs. The other alternative to installing node as the current user is commenting out the above lines and then running as root. But as this guide mentions, any time you run basil update you will have to comment out those lines again, which is not ideal.

As far as why we use npm link --local, we want the basil command to be on the user's path. Asking users to chown their /usr/local/ directory rather than running as root is actually recommended practice from the node community. We try to follow their recommendations whenever they apply.

We do plan on officially supporting Linux in the future but it has not been on top of our priority list just yet. That said, we welcome contributions from the community to make it work seamlessly on both OSX and Linux. :)

from devkit.

marti1125 avatar marti1125 commented on June 2, 2024

I hope to contribute for the version of linux.

from devkit.

mikehenrty avatar mikehenrty commented on June 2, 2024

@marti1125 ๐Ÿ‘

from devkit.

borfast avatar borfast commented on June 2, 2024

OK, I didn't know about that recommendation. But it's good I see it, because from now on I'll give less credit to node - a piece of software written by someone who suggests something like that, can not be trusted to be secure.

Seriously, that's scary. Especially given the context in which the guys suggests that - "don't use sudo to install packages because it can be dangerous; instead, open up a system directory to be written by your user and any trojans or malicious scripts the account may have."
Talk about shooting yourself on the foot. It makes no sense whatsoever.
ยซ/usr/local is supposed to be the stuff you installed, after all.ยป - indeed. In fact, the whole system was installed by me, so why not chown -R myuser / instead? It would make my life so much simpler. And secure as well! I would never have to worry about using sudo ever again!

Either way, even after installing node as a local user, devkit still didn't install correctly. It's a shame, I really liked what I saw but I guess I'll have to opt for something else.

from devkit.

mikehenrty avatar mikehenrty commented on June 2, 2024

I'm sorry you are having problems installing DevKit @borfast. If you would like to give it another shot, feel free to file a ticket at support.gameclosure.com and I will make sure we get you up and running. If not though, I understand, and I wish you luck in your future game development endeavors.

from devkit.

superlinkx avatar superlinkx commented on June 2, 2024

I would really like an official fix on this myself. I downloaded the devkit after seeing some of the cool stuff you guys are doing, but when I saw it suggest that I chown my /usr/local directory, I kind of lost interest. That's a terrible idea, even if the Node.js developers suggest it. Of course, they also aren't know for being the most secure environment on the block either. Point is, it's disappointing that this is the recommended route. Running as root is a slight step up, but not by much.

Why does it need to be installed to /usr/local exactly? As far as I can see, it's just adding basil to /usr/local/bin, in which case, using $HOME/bin would be a better alternative. Or at the very least, configure it to use $HOME/.local/ instead of /usr/local. That is the correct place to install user specific software on Linux, and is a much safer alternative to this whole mess.

I really hope you guys fix it. I really don't feel like spending the time updating all the source files to use $HOME/.local at the moment, but if you guys fix it, I'd really like to try out your engine for a game I'm wanting to write.

Anyways, hopefully, I've been able to help, while also giving some criticism where it's due. Seriously, the current way is extremely bad practice and should be fixed right away (shouldn't even take that much effort really, just rewrite all your /usr/local code to $HOME/.local

from devkit.

shteou avatar shteou commented on June 2, 2024

I believe as of the latest version this should now install locally for the user, it will optionally add a symbolic link to /usr/local/bin (after acquiring root permission through sudo) at the end of the installation process, but otherwise asks that you add devkitpath/bin/ to your PATH. I hope this is a reasonable solution.

Cheers,
Stew.

from devkit.

superlinkx avatar superlinkx commented on June 2, 2024

Glad to hear you got that worked out so quickly. I'll be trying it out later today. Thanks for the update

from devkit.

borfast avatar borfast commented on June 2, 2024

Great stuff! It works just fine - thanks guys!! ๐Ÿ‘

from devkit.

shteou avatar shteou commented on June 2, 2024

I'm guessing this can be closed off now. Any objections?
Regards.

from devkit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.