Re: build*.exe with pictures, icons...

2019-11-03 Thread Peter58
Yes, nimassets seems easy and interesting ... But the * .exe is it really standalone? What happens after the build, if I erase all the directory "templatesdir"? The * .exe will still work?

Re: Nimble RFC for project local dependencies

2019-11-03 Thread Araq
It's a good gist, but IMHO there is no need for the `--user` flag. I don't mind it enough to fight it though.

Nimble RFC for project local dependencies

2019-11-03 Thread shashlick
Requesting community feedback on the Nimble RFC that aims to enable project local dependencies - [issue 131](https://github.com/nim-lang/nimble/issues/131). I am tracking the proposal [in this gist](https://gist.github.com/genotrance/ee2ce321a56c95df2d4bb7ce4bd6b5ab) and request community

Fixed nim-mode for lem

2019-11-03 Thread edu500ac
I fixed nim-mode for lem. The main problem was in the syntax coloring for multi-line comment blocks. I also introduced missing items in the keyword list and in the type list. By the way, I did not fix spelling or grammar mistakes from the original authors. Therefore, words like _sepalador_ and

Cross Platform Python Package

2019-11-03 Thread sflennik
The nimformat project on github uses nim with nimpy to build a python module that can be packaged and installed with python's package manager (pip). The package includes the c source files and pip compiles them to build the python module on the target machine.

Re: Regex extracting string between two words not working

2019-11-03 Thread libraM
With some fixes: import re, strutils let buf = """ START { "start_h":10, "start_m":40, "end_h":11, "end_m":40, "delta_h":0, "delta_m":0, "project_ID":0 } END """ var dataBuf: string = ""

Re: build*.exe with pictures, icons...

2019-11-03 Thread shashlick
Alternative is [https://github.com/genotrance/nimdeps](https://github.com/genotrance/nimdeps).

longbow - a warband chess variant

2019-11-03 Thread smitty
in celebration of nim 1.x: [https://github.com/freevryheid/longbow](https://github.com/freevryheid/longbow)

Re: build*.exe with pictures, icons...

2019-11-03 Thread akavel
IIRC the compiler in GCC is named "windres.exe". Or was it in Visual Studio?

Re: build*.exe with pictures, icons...

2019-11-03 Thread aredirect
I encourage you to give nimassets a try [https://github.com/xmonader/nimassets](https://github.com/xmonader/nimassets)

Re: Nim equivilent of Python's slicing with step list[start: end: step]

2019-11-03 Thread hugogranstrom
It was interesting ;) I should use iterators more instead of hard to read loops with indices

Regex extracting string between two words not working

2019-11-03 Thread mronetwo
Hello, I hope it won't be a garbage post, because I'm missing something super simple... I'm sending a Json from a Python script to a server written in Nim. The Json data is between `START` and `END` strings. if "START" in buf: buildingRecord = true if

Re: Nim equivilent of Python's slicing with step list[start: end: step]

2019-11-03 Thread mratsim
There is none. Also if by sliced you meant that they share memory, it wouldn't be possible with normal seqs as they always copy (unless you use shallow() or you wrap them in an object with the {.shallow.} pragma like I do in Arraymancer)

Re: Nim equivilent of Python's slicing with step list[start: end: step]

2019-11-03 Thread kaushalmodi
If you use countUp in the loop, it will optimize your code a bit as it accepts the step size.

Nim equivilent of Python's slicing with step list[start: end: step]

2019-11-03 Thread hugogranstrom
I'm trying to get a slice of a seq but I only want every second element. I could write a loop that does this but I'm wondering if there is a more elegant way of doing it? In Python you can do: a = [0, 1, 2, 3, 4, 5] print(a[::2]) # Outputs: [0, 2, 4] Run I

Re: Converting a python thread toy application to nim

2019-11-03 Thread omgjfw
looks good. thanks!

Re: Converting a python thread toy application to nim

2019-11-03 Thread omgjfw
thanks. I think I need something like a threadpool. Everything else has survived conversion to nim except for the list of threads.

Re: build*.exe with pictures, icons...

2019-11-03 Thread Araq
For the exe icon you need to use a resource compiler and code like (taken from koch.nim): when defined(gcc) and defined(windows): when defined(x86): {.link: "icons/koch.res".} else: {.link: "icons/koch_icon.o".} when defined(amd64) and

Re: build*.exe with pictures, icons...

2019-11-03 Thread juancarlospaco
`staticRead`

build*.exe with pictures, icons...

2019-11-03 Thread Peter58
Can we compile a script by directly embedding images and / or icons in the the * .exe file... instead of having them separately?