this is what i use for web development:
* for static files, i use nginx and convert markdown to html using
guile-commonmark, with an extension that allows calls to scheme code
inside markdown (https://github.com/sph-mn/sph-web-publish) to generate
some content like file listings
* for dynamical
ive started https://github.com/sph-mn/sph-sc and have been using it a
lot over the years and worked through several c edge cases. i enjoy
using it, more and more even. the git repository page contains several
hints and ideas on the general topic. i you have any questions, i'd be
happy to answer
surely not the ideal way to generate numbers with a normal distribution,
but there is a way to use custom probabilities from a list, which i
think is nice to know.
it works like this:
have a list of probabilities. can be as long as you want. i think that
is called probability density.
->
(1 0
i think it is possible to restrict the bindings available for code that
is evaluated with eval-in-sandbox. eval-in-sandbox accepts a keyword
argument named #:module for supplying a module object which gives all
bindings that will be available to the evaluated code. a module with the
allowed bin
You know what would be great? If you packaged "sph-lib" for GNU Guix
that is a good point, i plan on trying to do that, again. with the last
two tries i couldnt find a simple example or documentation for creating
a guix package that doesnt use autotools.
i once wrote a rfc3339 reader/writer and worked through some gotchas, maybe the
code contains hints that are helpful.
for example, here is a function that converts from a timestamp to a rfc3339
date string:
(define* (utc->rfc3339 a #:optional (offset 0) (seconds-fraction 0))
"integer:posi
i once wrote a rfc3339 reader/writer and worked through some gotchas,
maybe the code contains hints that are helpful.
for example, here is a function that converts from a timestamp to a
rfc3339 date string:
(define* (utc->rfc3339 a #:optional (offset 0) (seconds-fraction 0))
"integer:posi
i dont know if it is possible, but the source code of srfi-37 is available, on my machine
it is at /usr/share/guile/2.2/srfi/srfi-37.scm. i didnt see an option for the
"--name value" case at first glance.
apparently the --name=value syntax is to allow for long options with optional values. othe
only thing is, im not sure yet what i would set LD_LIBRARY_PATH to, as the
following are all the library files gsl installs:
gsl /usr/lib/libgsl.so
gsl /usr/lib/libgsl.so.23
gsl /usr/lib/libgsl.so.23.1.0
gsl /usr/lib/libgslcblas.so
gsl /usr/lib/libgslcblas.so.0
gsl /usr/lib/libgslcblas.so.0.0.0
so far i couldnt find the cause with strace.
mmap(NULL, 80013, PROT_READ, MAP_PRIVATE,
7, 0) = 0x7f6a6da6b000
close(7)
= 0
mprotect(0x7f6a6da7b000, 8776, PROT_READ|PROT_WRITE)
= 0
openat(AT_FDCWD, "/usr/lib/libgslcblas.la", O_RDONLY)
im getting the error "In procedure dynamic-link: file: "libgsl",
message: "file not found"" with the following code:
(import (system foreign))
(define gsl (dynamic-link "libgsl"))
* gsl (optionally?) depends on libgslcblas, which itself links without
error, but loading it with (dynamic
i might not be able to be of much help but ive used fibers before in a
server application.
there is a pitfalls section in the manual:
https://github.com/wingo/fibers/wiki/Manual
here is the code of the server application, which has code
idiosyncracies, like using first/tail instead of car/cdr
im sure it is not the optimal way to do it, and currently it fails on
file access errors and there might be bugs, but it has cool features and
i just wanted to share.
filesystem globbing is the matching of paths that can include wildcard
characters like asterisks.
the code implements the follo
hi, not sure if it is exactly what your looking for but it might be
useful for examples and matches the general question.
i maintain a project named "web-app" at http://sph.mn/c/view/mu or
https://github.com/sph-mn/sph-web-app
the core is small and working well for me so far, ive been maintaining
i use scheme-like syntax to write c and javascript, and i do this with
two transpilers that ive recently revised.
you might have looked at sc and sescript in the past, but what ive
changed now is that i removed features that dont map directly to a
single c syntax form and straightened things out
le to extract macro parameters from exported syntax
transformer procedures.
On 2017-09-25 14:01, Christopher Howard wrote:
On Sun, 2017-09-24 at 00:47 +0000, tantalum wrote:
* i don't repeat the procedure name and parameter names because that
canĀ
be queried at run-time or automatically
i don't know of common conventions, but here is what i do:
* i don't repeat the procedure name and parameter names because that can
be queried at run-time or automatically extracted
* most of the time i write a type signature in the first line of
docstrings because i find that information useful
hi
(ice-9 popen)
https://www.gnu.org/software/guile/manual/html_node/Pipes.html
is the only module that can create sub-processes with pipe input/output
and does not use shell. it takes a program name and runs it as a
sub-process with a pipe connected to its input/output. but its limited
in th
Amirouche Boubekki wrote:
On 2016-12-22 19:09, tantalum wrote:
Would it be possible to have that list using an xml format that can
be consumed by search engines?
yes. do you have a specific format in mind? i have heard of "sitemap"
format
I was thinking about sitemap indeed.
Fun!
already been used in the same sentence.
here is the source code:
http://files.sph.mn/s/computer/create-marketing-bs.scm
On 2016-12-21 19:34, Amirouche Boubekki wrote:
On 2016-03-24 00:10, tantalum wrote:
i am happy to announce a new version of the (sph cli) library for
command-line option parsi
hi
last time i mentioned it was a few years ago, and i just thought i let
you know that sph-sc got some interesting updates recently, and plcss
and sescript (as well as sph-lib) are still actively maintained.
"sc", for those who have not heard of it, is c written with
s-expressions. it looks
i am happy to announce a new version of the (sph cli) library for
command-line option parsing.
a big new feature besides general improvements is integrated support for
sub commands similar to what "git" has (git push, git pull and the
like).
the library documentation and overview can be found h
here is a list of projects with code that guile can run and projects that use
guile:
http://sph.mn/content/3e73
i made this list and would be interested in hearing about projects i have
missed.
Ginrut wrote:
Hi tantalum!
This seems cool!
I'm considering a better memory mapped database for storing sessions in
Artanis. Now I'm using common hash table.
I saw you project is based on LMDB which is a lightweight no-sql DB. Is
it proper for my purpose?
Thanks!
On Mon, 2014-11-03 at 2
hi. in the past year i have implemented my idea of how a basic graph
database should look like, with guile. and today it seems quite stable
and usable.
it uses a memory-mapped data store to persist bi-directionally ordered
(or weighted) pairs (what would be edges of a graph), bytevectors,
strings
hi
i used guile programs behind nginx, lighttpd and apache and maybe i can
help.
if you just like to have an http server, guile includes an
implementation
(http://www.gnu.org/software/guile/manual/html_node/Web-Examples.html#Web-Examples)
if you are looking for running an application behind anothe
Neat. Just to double-check - the environment variables of my current
process are
preserved or /tmp/mybin would run with environment consisting only of
variables which
I've explicitly put into execute-with-environment?
the new process receives only the specified environment variables. but
it sho
I'd like to spawn proc1 with DISP=X1, proc2 with DISP=X2 etc and
> I'd
> like to save that into record with (proc1, X1, pid1), (proc2, X2, pid2)
>
> How do I implement it using 'process' and 'record' from sph.io? How do I
> later access
> pid2 for e
> Are there some code examples?
except for process-chain-* probably not, but i put that on my todo list.
something like this should work:
(execute-with-environment "XX2=LOL" "/tmp/mybin")
working example:
guile -c '(import (sph process)) (execute-with-environment (list
"XX2=LOL") "/usr/bin/ec
i am sorry, i am late... i was not subscribed to the list. i maintain
the site
yes, the site is unstable. despite that, it should always restart
automatically, please try again, and when you see a 403 that probably
means it is just starting, 502 that it just crashed ...
at first i had to rewrite
several gpl3 licensed guile modules:
sph-lib - a collection of libraries and example implementations
cli: quickly create a command-line interface
test: write and execute code tests
test-performance: compare performance between arbitrary procedures
lang-plcss: language for creating cascadin
Hi
The (ice-9 streams) module could be interesting, too.
http://www.gnu.org/software/guile/manual/html_node/Streams.html
Example:
-
(import
(ice-9 streams)
(ice-9 rdelim))
(define (port->line-stream port handle-delim)
(port->stream port (lambda (port) (read-line port handle-del
Hi,
I did write a guile-dbi module for sqlite3.
I am using it everyday successfully for basic queries.
You can find it under: http://thaseph.de/ande/guile-dbd-sqlite3.html
Hope it helps
age:
ERROR: Unbound variable: gdk-event-keyval
thanks for your help!
Julian
----
tantalum wrote:
> Hi,
>
> Can anyone show me with a little code snippet, how to
> check for a specific key pressed with a key-press-event? I could not
> find the answer myself.
>
>
(gtk-signal
Hi,
can anyone help me with this build related problem?
Is there something I am missing?
guile 1.8.6
guile-sdl 0.3.10
kernel linux 2.6.29-ARCH
sdl 1.2.13
sdl_image 1.2.7
"./configure --prefix=/usr && make"
--
Making all in src
make[1]: Entering directory `/tmp/guile-sdl-0.3.10/src'
make all-re
hello
i think guiles project page could need at least 2 small changes.
1
replace the link 'anonymous cvs' under 'getting guile' with one to the
more up to date page,
this one: http://www.gnu.org/software/guile/repository.html
2
that page says to use 'git-clone', which does not exist on my sys
36 matches
Mail list logo