logoalt Hacker News

mook • today at 6:31 AM • 5 replies • view on HN

I know this is not really the case for many others, but for me it's because there's a lot of set up; that's usually done by IDEs, but I'm unlikely to get an IDE before I've kicked the tires a bit. Go is run "go mod init", or hand write one, or even skip that step to write a single file thing. JavaScript is similar, you can start with one file, or start with a relatively simple package.json. Python / ruby / Perl / PHP is just the one file.

As far as I know, C# and friends still require setting up a project file, and there isn't a tutorial that has one you can easily copy.

Maybe this is why I also can't get into Android development.

(It also doesn't help that my Linux distro doesn't ship the toolchain because it can't be bootstrapped from text files, as far as I understand it)


Replies

iCarrot • today at 6:46 AM

Does `dotnet new <template>` not count?

You could also `dotnet run script.cs` to run a single file without setting up project.

eeeficus • today at 6:41 AM

This used to be true but is very much false now! The CLI can create any new project, even complicated ones. You can create your own project templates if you want. You can even start a solution and project files in an editor. It’s all just xml!

EMM_386 • today at 7:27 AM

This should do it:

dotnet new console

dotnet run

jve • today at 6:45 AM

[flagged]

vortegne • today at 7:49 AM

You are exactly proving the parent comment right!