<xificurC>
for people like me who are behind a firewall that decided to block pastebin.com and some other famous paste sites it would be of great help if you used a site like https://ix.io
<xificurC>
it is actually a nice alternative as you can throw a file at it in the command line, or your clipboard etc. and it will paste it and return the link
<Regenaxer>
Cool indeed!
<Regenaxer>
Is there a debian package for ix?
<xificurC>
I'm not a mouse person so I enjoy minor boosts like this :) Anyway, this is a selfish request but I would be able to see your pastes :)
<Regenaxer>
yeah, I always prefer command line tools
<xificurC>
I don't think there's a package, the command line script is just 1 shell function
<Regenaxer>
I see, just pipe eg. with curl?
<Regenaxer>
What is that 'f:1=<-' argument doing4
<xificurC>
There's examples on the page I sent, but the most basic way is
<Regenaxer>
?
<xificurC>
curl -F 'f:1=<-' ix.io which sends stdin, so
<xificurC>
curl -F 'f:1=<-' ix.io <file
<Regenaxer>
yes
<xificurC>
curl -F 'f:1=<-' ix.io < <(xsel -b)
<xificurC>
-F is for form, f is the name of the field of the form, :1 I don't know, <- is "take stdin" curl notation
<xificurC>
in a different folder? I don't know, not watching over your shoulder :)
<Regenaxer>
no, it was the same file
<Regenaxer>
anyway, really cool, I keep in my bash history
<xificurC>
:)
rob_w has quit [Quit: Leaving]
<Regenaxer>
I should put an "ix.io" command into Vip, so I can send directly the current buffer :)
<Regenaxer>
Until now I always save to a file, start w3m on pastebin, navigate, edit the text area (also with Vip), save and create paste. A lot of work!
<cess11>
When I'm on the bus I'll see if I can work out some tinies for using that service, looks nice.
andyjpb has joined #picolisp
alexshendi has joined #picolisp
<xificurC>
Regenaxer: shouldn't be too hard to add it I guess :) I would advise to call it "pb" for pastebin (or pastebuffer :) , I used http://sprunge.us before but it died for a while and people switched to a new backend
alexshendi has quit [Ping timeout: 268 seconds]
pierpal has quit [Quit: Poof]
pierpal has joined #picolisp
<Regenaxer>
ok, though I thought here (opposed to my usual taste) to use a longer command name. The reason is not to paste something to the public unintentionally ;)
<tankf33der>
importing data, speed!
<xificurC>
publishBuffer ? :)
<Regenaxer>
hmm, well, not sooo long ;)
<Regenaxer>
just "ix.io"
<Regenaxer>
Perhaps there is another such service in the future?
<xificurC>
inbefore you write your own pasting service
<xificurC>
now I screwed something up really hard :)
<Regenaxer>
:)
<xificurC>
? : !? (key)
<xificurC>
Select error: Bad file descriptor
<Regenaxer>
Destroyed stdin somehow :)
<xificurC>
app/main.l doesn't call (app)
<Regenaxer>
yes, done in 'work'
<Regenaxer>
in app/gui.l
<xificurC>
maybe that's the problem?
<Regenaxer>
no, without (app) you get single-shots, just no session
<xificurC>
I had (app) (server 8080 "!work"), that didn't work :)
<xificurC>
now I added a call to (app) in work
<xificurC>
works.
<xificurC>
what doesn't work as intended is this snippet
<xificurC>
(gui 'what '(+TextField) 100)
<xificurC>
'(set> (: home what) (list *Server *Env *Prjs *Name)))))))
<xificurC>
(gui '(+JS +Button) "Search"
<Regenaxer>
It should set a text, a string
<xificurC>
the globals are defined elsewhere but the textfield doesn't show their values as expected, on first click it shows nothing and on second _____
<Regenaxer>
not sure what happens with a list
<xificurC>
how do you turn it into an e.g. space-joined string?
<xificurC>
yeah I wanted to put @lib.css into allowed put into load
<Regenaxer>
hehe
<xificurC>
http://ix.io/1gYJ I still don't see the value in the field
<xificurC>
I put values in the field but get just 3 spaces
<Regenaxer>
hmm, I can see no obvious error
<Regenaxer>
The globals have all values?
<xificurC>
http://ix.io/1gYL here's the full source, running as pil main.l +
<xificurC>
I put values in some fields, not all
<Regenaxer>
ok
<xificurC>
querying the values in the debugger REPL shows NIL for everything but I'm not sure, would it show the session's values?
<Regenaxer>
What if you do '(set> (field -1) ... ?
<Regenaxer>
should be the same though
<Regenaxer>
Yes, I meant in the REPL
<Regenaxer>
: *Server
<Regenaxer>
should be there
<xificurC>
still just 3 spaces
<cess11>
You probably need a submit to actually store the values in the variables, or perhaps just '+JS on those fields or something.
<Regenaxer>
The submit is done by the button
<xificurC>
all vars are NIL in the REPL
<Regenaxer>
This why nothing is stored
<Regenaxer>
only " "
<Regenaxer>
But why are they empty?
<xificurC>
hey, that's my question! :)
<Regenaxer>
Looks like the session is not unique ;)
<xificurC>
hm?
<Regenaxer>
you get a : prompt, in the normal way?
<xificurC>
% pil main.l +
<xificurC>
11589 = 52393 33391547664262078~
<xificurC>
-> NIL
<xificurC>
: *Server
<Regenaxer>
ok, let me try here
<xificurC>
do I need to allow globals as well?
<xificurC>
that's just for URL referencing no?
<Regenaxer>
yes, no need to allow
<Regenaxer>
They are not passed in transactions
<xificurC>
I want to build a +QueryChart in the end, thinking that's what I need :) It's just a simple query into the DB to show the values. I wanted to start things simple, so I thought a few globals and 1 button showing their values should be simple, right? :)
<xificurC>
I'm still dreaming of writing my own forth. And lisp
<Regenaxer>
I'd loved to write a Lisp *in* Forth, if it were not a performance issue
<xificurC>
on a forth chip it wouldn't :p
<Regenaxer>
I think Forth is inherently slow, due to excessive stack handling
<xificurC>
I'm sure Chuck would disagree :)
<Regenaxer>
The whole stack needs to be in registers
<Regenaxer>
yes, I know
<Regenaxer>
But all claims about the speed of Forth never turned true
<xificurC>
his chip claims to have register-like-speed access of the stack
<Regenaxer>
Just like Java/JIT
<Regenaxer>
But iirc his chip has an extremely tiny stack
<xificurC>
I remember 9, might be a bit more
<Regenaxer>
yeah
<xificurC>
"chosen as effectively infinite"
<Regenaxer>
no chance for recursion
<xificurC>
I was talking about the datastack
<xificurC>
but the callstack is of same depth I think
<Regenaxer>
yes, is needed in recursion too
<Regenaxer>
data stack
<xificurC>
his words are usually : foo something IF finish THEN something foo ;
<xificurC>
which is basically a tail-call optimized call (a jump)
<Regenaxer>
T
<Regenaxer>
only a loop
<xificurC>
yes
<Regenaxer>
no tree traversal etc
<xificurC>
but you are right that the data stack is used in some recursion schemes too
<Regenaxer>
I think it is needed in all
<xificurC>
. (number printing) in freeforth e.g. uses the datastack
<Regenaxer>
yes, reversing
<xificurC>
well depends on the case. Some loops just do side effects
<Regenaxer>
But where recursion is *needed* is tree traversal
<xificurC>
T
<Regenaxer>
and there you recurse on data, keeping the state on the stack
<xificurC>
his chips have something like 64K RAM. No big trees there :D
<xificurC>
64 words actually
<Regenaxer>
true, but trees can be abstract, eg a search with backtracking
<Regenaxer>
not in memory
<Regenaxer>
a robot moving around
<xificurC>
yes, I understand
<xificurC>
the chip is limited, on purpose
<Regenaxer>
yeah, and massively parallel iirc
<xificurC>
whether we agree with the purpose or not is a different discussion :)
<xificurC>
yes, they sell a board with 144 chips
<Regenaxer>
It is fascinating, I just don't have a use case at the moment ,)
<Regenaxer>
:)
<xificurC>
anyway, there are a few ANS forth that have pretty advanced optimizing compilers (swiftforth and the other I forgot)
<Regenaxer>
The code speed is not the problem
<xificurC>
oh?
<Regenaxer>
it is data access due to the stack architecture
<Regenaxer>
over dup swap etc
<Regenaxer>
direct register operations are faster
<Regenaxer>
add A (X CDR)
<xificurC>
optimizing compilers do compile those away. If they load the top 3 stack items into 3 registers they don't need to xchg
<xificurC>
only on word boundaries
<Regenaxer>
yeah, but when it gets deeper they need to flush to the stack
<Regenaxer>
too complex
<Regenaxer>
such a compiler also adds complexity
<xificurC>
I will believe you, my knowledge is theoretical and blog-post-based :)
<Regenaxer>
I finally gave up Lifo because it is tedious to program, not for performance
<Regenaxer>
in fact Lifo was faster than Pil
<Regenaxer>
But the stack handling is simply tedious
<xificurC>
but I believe the claims that working with the stack forces the dev to think about optimal data flow and data structures, often leading to superior design, which might at some point outrun a typical C solution
<Regenaxer>
keeping track of the stack
<Regenaxer>
Perhaps, but I found it does not match my way of thinking
<xificurC>
I have yet to write enough forth code do form my opinion on stack juggling
<xificurC>
*to form*
<Regenaxer>
Short examples are elegant and nice
<xificurC>
I don't think it matches anyone's kind of thinking :D
<Regenaxer>
But programming it all day is tiresome