Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 04 21:48
    bakpakin closed #996
  • Jul 04 21:48

    bakpakin on master

    Fix #996 - linking command work… (compare)

  • Jul 04 21:26
    bakpakin labeled #996
  • Jul 04 21:24
    bakpakin commented #996
  • Jul 04 21:24
    bakpakin commented #996
  • Jul 04 18:23
    LeviSchuck opened #996
  • Jul 04 16:27
    tionis opened #995
  • Jul 03 17:29

    bakpakin on master

    Allow shorthand for setting tas… (compare)

  • Jul 03 06:00
    pepe commented #991
  • Jul 03 05:34
    pepe commented #993
  • Jul 03 02:11

    bakpakin on master

    Fix function handlers for :out … Merge branch 'master' of github… (compare)

  • Jul 02 17:30

    bakpakin on master

    Use relative path for include/j… Merge pull request #994 from sh… (compare)

  • Jul 02 17:30
    bakpakin closed #994
  • Jul 02 17:29
    bakpakin commented #994
  • Jul 02 15:52
    shassard synchronize #994
  • Jul 02 15:45
    shassard opened #994
  • Jul 02 15:38
    bakpakin closed #788
  • Jul 02 15:38
    bakpakin commented #788
  • Jul 02 14:31

    bakpakin on master

    Add basic test for tabseq Merge pull request #993 from pe… (compare)

  • Jul 02 14:31
    bakpakin closed #993
saikyun
@saikyun
Do you have eval buffer in ijanet? :)
If you want to keep state around, you can implement defonce: https://github.com/janet-lang/janet/discussions/607
I don't know anything about circlet though
Levi R. I. Tan Ong
@levitanong
ah sorry, i phrased it weirdly. I'm running ijanet on emacs (and yes i have the eval buffer) and i'm trying to use circlet, which is a webserver based on mongoose. It has a (while true) to keep the server running, and it seems like the repl is blocked while this is happening. Having said this, I realize the solution might simply be to wrap it in a coroutine. That would make it async, and perhaps not block the repl.
andrewchambers
@andrewchambers
I think you need to consider which bits of state are persistent and which are not
and use vars
and manually code some reloading logic
but i think its possible
saikyun
@saikyun
I solved a similar problem with netrepl and ev/call. Relevant bits of code: https://github.com/Saikyun/text-experiment/blob/main/src/main.janet#L503
I also used dofile to get an env and merge it into the root env: https://github.com/Saikyun/text-experiment/blob/main/src/file_handling.janet#L54
@sogaiu:matrix.org has some info about using netrepl from Emacs, but I'm not sure if that code is public
Zach Smith (subsetpark)
@subsetpark:matrix.org
[m]
There’s an ijanet now??
sogaiu
@sogaiu:matrix.org
[m]
i think the emacs netrepl code i have is here: https://gist.github.com/sogaiu/aa957885d965e4b874fc83c55f873719
@subsetpark: may be you found it already, but iiuc, ijanet refers to this: https://github.com/SerialDev/ijanet-mode
andrewchambers
@andrewchambers
@bakpakin:matrix.org i sometimes wonder if polymorphic number functions should have just called methods instead of using polymorphic operators. It seems more orthogonal
e.g.
(:+ a b)
it seems pretty clear what is going on
so the answer to writing a polymorphic formula would have been to use methods for everything
i guess that would have required methods on things like Number
the syntax doesn't even look that bad imo
i guess it would put you in the situation that to use int/s64 you would be required to use methods
andrewchambers
@andrewchambers
in hind sight i think basically everything numeric function that is polymorphic should be under a namespace like
poly/pos? poly/max poly/min ...
and they would be implemented in terms of methods
I think its currently quite error prone in the stdlib to use any of the standard functions with abstract number types
since a bad comparison often silently returns true or false
due to total ordering
andrewchambers
@andrewchambers
but yeah, i feel like method calls should be the way to do polymorphism
im not sure the real value having + call a method on fallback provides
andrewchambers
@andrewchambers
perhaps the fact that numbers do not have methods pulled janet towards having special semantics in operators
though i think it might not be that bad to do static method lookup for primitive types
in the method call opcode
anyway, not sure this is a good idea or not, just some thoughts
andrewchambers
@andrewchambers
bah, wrong chat, sorry
Levi R. I. Tan Ong
@levitanong
Thanks @Saikyun and @andrewchambers ! I will digest this over the coming days.
yumaikas-
@yumaikas:matrix.org
[m]
So, is anyone keeping a Janet dockerfile around? I'm planning on using docker to help packat a project, and I am willing to write one, but wanted to check for prior art
Never used it for anything, but tested that it works. I settled for the classic PHP "files on the server" approach
andrewchambers
@andrewchambers
@yumaikas:matrix.org how does docker help? do you depend on some system library?
yumaikas-
@yumaikas:matrix.org
[m]
It helps by giving me a cross platform "Run this to check out this janet project"
Instead of trying to cross compile, or have the people in question go through the Janet installation process
andrewchambers
@andrewchambers
@yumaikas:matrix.org but then don't people need to deal with the Docker installation process?
for me that was a lot worse
yumaikas-
@yumaikas:matrix.org
[m]
@andrewchambers: this is a program for a specific set of people I expect to be more familiar with Docker than Janet, not a general distribution of code. Otherwise I'd share your concerns
ahungry
@ahungry:matrix.org
[m]
Janet in docker is a nice sandbox, perhaps easier to setup than a chroot for web janet and so small via alpine
Janet cross platform is fun but tricky
andrewchambers
@andrewchambers
i uninstalled docker after i started doing backups and seeing all the shit it does pointlessly every second to my filesystem, even when idle. Not a fan haha.
I liked rocket a lot more, too bad it died