November 09
On Friday, 9 November 2018 at 00:18:28 UTC, H. S. Teoh wrote:
> It's not true that you're stuck with dub.  And I'm not among the people who think dub is the way to go (though it's true that that's a minority opinion around here).  Where I have a choice, my own D projects do not use dub.
>
> I have one project that uses dub because it's based on vibe.d, but I mostly avoid needing to use dub by creating an empty dub project in a subdirectory whose sole purpose is to declare a dependency on vibe.d. Then I build that once with dub, and outside in my real project I just link directly to the produced artifacts. (The exact path(s) to the dub products can be extracted from the output of `dub -v`. This can probably be automated and translated into your build system of choice, though I haven't quite gone that far yet.)  Then I don't need to use dub except when upgrading the dub-dependent library.

This is still a build system though. It might have advantages over Dub, but I think the OP wants to avoid build systems altogether. Someone coming from a scripting language wants to add

import foo;

to their program and not think about package foo further. There's no obvious reason it can't be done that way in D, but the C/C++ foundation of this community leads to a mindset that it's wrong, because you need to be able to set all kinds of configuration options, guarantee reproducible builds, etc. All of which are of no importance to someone using D as a scripting language.
November 09
On Friday, 9 November 2018 at 00:18:28 UTC, H. S. Teoh wrote:
> It's not true that you're stuck with dub.  And I'm not among the people who think dub is the way to go (though it's true that that's a minority opinion around here).  Where I have a choice, my own D projects do not use dub.

Me neither, I think it's a lot of work for little benefit and doesn't seem all that easy to use either. I rather use rdmd using -I flags.
November 09
On Friday, 9 November 2018 at 01:18:51 UTC, bachmeier wrote:
> There's no obvious reason it can't be done that way in D

It is trivial, really. Just download the files to your import path and `dmd -i`. Only hard part is the modules need to be arranged such that dmd -i will find it... and the dub package layout isn't compatible with it... lol.

But my libs are :P


We could probably write a downloader that reads module declarations and arranges them in an installed libs folder. Very simplified "install library" thing whose initial setup could set the dmd conf stuff so it just works (or wraps dmd slightly to add -I and -i to build it)...

November 09
On Fri, Nov 09, 2018 at 05:38:18PM +0000, Adam D. Ruppe via Digitalmars-d-learn wrote:
> On Friday, 9 November 2018 at 01:18:51 UTC, bachmeier wrote:
> > There's no obvious reason it can't be done that way in D
> 
> It is trivial, really. Just download the files to your import path and `dmd -i`. Only hard part is the modules need to be arranged such that dmd -i will find it... and the dub package layout isn't compatible with it... lol.
> 
> But my libs are :P
> 
> We could probably write a downloader that reads module declarations and arranges them in an installed libs folder. Very simplified "install library" thing whose initial setup could set the dmd conf stuff so it just works (or wraps dmd slightly to add -I and -i to build it)...

Do it!  That would be a welcome convenience for importing 3rd party code where the full machinery of dub isn't necessary.


T

-- 
If creativity is stifled by rigid discipline, then it is not true creativity.
November 10
On Thursday, 8 November 2018 at 23:51:39 UTC, bachmeier wrote:
> On Thursday, 8 November 2018 at 23:43:38 UTC, Murilo wrote:
>
>> It finally worked, but I can't just compile it normally, I have to use dub run, I wish it were something simple that I just download into the folder and then use an import statement and then compile it like any other program. I wish it were as simple as using std.stdio for example.
>
> Unfortunately your stuck with Dub if you want to use D. It's an awful experience compared to Python and other scripting languages, so I understand what you're saying, but most people around here think Dub is the way to go.


Stop bashing dub. Its completely fine for me. I don't get what OP mean by "simple" but:

dub init
add package name
dub run

... doesn't look "not simple" to me.
6 days ago
On Saturday, 10 November 2018 at 20:04:21 UTC, aberba wrote:
> On Thursday, 8 November 2018 at 23:51:39 UTC, bachmeier wrote:
>> On Thursday, 8 November 2018 at 23:43:38 UTC, Murilo wrote:
>>
>>> It finally worked, but I can't just compile it normally, I have to use dub run, I wish it were something simple that I just download into the folder and then use an import statement and then compile it like any other program. I wish it were as simple as using std.stdio for example.
>>
>> Unfortunately your stuck with Dub if you want to use D. It's an awful experience compared to Python and other scripting languages, so I understand what you're saying, but most people around here think Dub is the way to go.
>
>
> Stop bashing dub. Its completely fine for me. I don't get what OP mean by "simple" but:
>
> dub init
> add package name
> dub run
>
> ... doesn't look "not simple" to me.

It will pay some of us if you explain more on how to us dub. To me dub is too difficult to us and is not user friendly. It is not every body who is interested in Dlang is in a country with strong internet connection. A tutorial on how to use dub will really help. I don't need a link as i have gone through them but did not help me. How i wish dlang tools will be as simple and user friendly as the language itself.
6 days ago
On Friday, 9 November 2018 at 17:38:18 UTC, Adam D. Ruppe wrote:

> But my libs are :P

I'm aware. That's why I use your libraries but Dub not so much.
Next ›   Last »
1 2