Post 2142909 by jalcine@playvicious.social
(DIR) More posts by jalcine@playvicious.social
(DIR) Post #2142116 by jalcine@playvicious.social
2018-12-20T20:31:08Z
0 likes, 1 repeats
okay time to start something #dev / #webdevWhat format should I use for configuration?> ToML / YAML> JSON> INI> XML
(DIR) Post #2142117 by jalcine@playvicious.social
2018-12-20T20:31:57Z
0 likes, 1 repeats
To be honest (and awkward), I want to use XML or JSON because #Koype already has one for parsing remote pages and data.This is for theming (some light notes here): https://git.jacky.wtf/indieweb/koype/wiki/Theming
(DIR) Post #2142258 by Are0h@playvicious.social
2018-12-20T20:37:50Z
1 likes, 0 repeats
@jalcine I usually go with JSON. Easy to manipulate.
(DIR) Post #2142259 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:41:25.963453Z
3 likes, 0 repeats
@Are0h @jalcine why do people think they need to add another lang to they project. you have object literals already, just use those. config.(js|scm|...)
(DIR) Post #2142501 by jalcine@playvicious.social
2018-12-20T20:43:51Z
0 likes, 0 repeats
@xj9 Object literals are cool but at times you'd want to do versioning of the configuration's schema, automatic type casting, simple serialization (all but one come for free).There's also the whole hype behind adding some of those platform-specific language formats. @Are0h
(DIR) Post #2142502 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:48:08.531330Z
0 likes, 0 repeats
@jalcine @Are0h so you’re planning to independently version the config format and the program? you also lack the ability to validate plain javascript objects? doubtful imo. type casting? you do realize that you said this was a web project, right? you already barely have types. using json won’t help you here.
(DIR) Post #2142693 by Are0h@playvicious.social
2018-12-20T20:51:49Z
0 likes, 0 repeats
@xj9 @jalcine json is javascript. I'm not sure what your gripe is here.
(DIR) Post #2142694 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:53:33.138759Z
0 likes, 0 repeats
@Are0h @jalcine JSON is a *subset* of JavaScript to be exact.my gripe is against config files. you really do *not* need them to be written in special languages. you have language already. just. use. it.
(DIR) Post #2142746 by jalcine@playvicious.social
2018-12-20T20:52:53Z
0 likes, 0 repeats
@xj9 I did say it's a Web project but this configuration parsing is happening server-side in Elixir (types are a thing there, language assumption might be clouding judgement here). In Elixir, I could just pipe in something similar to a "x-path" and have a clause that matches. Very direct! And that can contained in a singular module that represents v1 of the config @Are0h
(DIR) Post #2142747 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:54:55.722914Z
0 likes, 0 repeats
@jalcine @Are0h alight then use Exlir files. the point is, you don't need to add another language to the project in order to configure it.
(DIR) Post #2142783 by jalcine@playvicious.social
2018-12-20T20:55:19Z
0 likes, 0 repeats
@xj9 @Are0h FWIW: https://playvicious.social/@jalcine/101275307162379677I do want to introduce configuration options that don't require too much explanation for people (read: non-tech people).
(DIR) Post #2142784 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:56:18.614471Z
0 likes, 0 repeats
@jalcine @Are0h i really doubt non-tech people would ever be the ones editing json files either.
(DIR) Post #2142873 by Are0h@playvicious.social
2018-12-20T20:57:16Z
0 likes, 0 repeats
@xj9 @jalcine ha, json isn't a 'special language' it's just jsthis is boring. enjoy your day.
(DIR) Post #2142874 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:58:43.303868Z
0 likes, 0 repeats
@Are0h @jalcine ECMA-404 and ECMA-262 are actually very different standardsyou should read them some time
(DIR) Post #2142909 by jalcine@playvicious.social
2018-12-20T20:58:45Z
0 likes, 0 repeats
@xj9 @Are0h You know a lot about the users I'm working with for this project, it seems.
(DIR) Post #2142910 by 361.xj9@social.sunshinegardens.org
2018-12-20T20:59:39.842767Z
0 likes, 0 repeats
@jalcine @Are0h what makes JSON easier to edit than elixir config files? you have evidence?
(DIR) Post #2142960 by Are0h@playvicious.social
2018-12-20T21:00:22Z
0 likes, 0 repeats
@xj9 @jalcine And json is still js.Being a dickhead about it isn't going to change that fact.
(DIR) Post #2142961 by 361.xj9@social.sunshinegardens.org
2018-12-20T21:01:06.101152Z
0 likes, 0 repeats
@Are0h @jalcine JSON is a serialization format JavaScript is a programming language idk why its so hard for you to tell them apart
(DIR) Post #2143064 by jalcine@playvicious.social
2018-12-20T21:02:58Z
0 likes, 0 repeats
@xj9 @Are0h I could sit down here and do the work for you of linking all of the toots that I made after the first one I made that @Are0h replied to.You seem to be a data-driven person though, so I'll let you do that and I can get back to working on my configuration parser.
(DIR) Post #2143065 by Are0h@playvicious.social
2018-12-20T21:03:50Z
0 likes, 0 repeats
@jalcine @xj9 Yeah, take me out of this. This thread is non-sense.
(DIR) Post #2143066 by 361.xj9@social.sunshinegardens.org
2018-12-20T21:04:21.195191Z
1 likes, 0 repeats
@Are0h @jalcine blocked
(DIR) Post #2148331 by chucker@mastodon.social
2018-12-21T00:15:02Z
0 likes, 0 repeats
@xj9 @Are0h @jalcine a programming language for configuration is* harder for those editing it to grok (there’s invariably more syntax)* harder to parse and validate* likely to introduce reliability and security issuesIf you must have automation in your config (really? You sure about that?), you’d want it to be a sandboxed subset. Orrrr you could just use a config language.
(DIR) Post #2148332 by 361.xj9@social.sunshinegardens.org
2018-12-21T00:16:02.129503Z
1 likes, 0 repeats
@chucker @jalcine @Are0h ok, except i'm right and you should just use the regular language
(DIR) Post #2148873 by Are0h@playvicious.social
2018-12-21T00:22:31Z
0 likes, 0 repeats
@chucker @xj9 @jalcine Yo, take me out of this. I'm not debating this non-sense.
(DIR) Post #2148874 by 361.xj9@social.sunshinegardens.org
2018-12-21T00:49:37.398434Z
2 likes, 0 repeats
@Are0h @jalcine @chucker “debate” implies that i could be mistaken. which i am not. https://social.sunshinegardens.org/media/afe26949-3b6c-4418-9132-7b862d1f56bc/file.jpg
(DIR) Post #2149897 by Are0h@playvicious.social
2018-12-21T00:51:01Z
0 likes, 0 repeats
@xj9 @jalcine @chucker LOL, if you really believed that, you wouldn't still be here trying to convince us of it.And wasn't I blocked? Go back to doing that.
(DIR) Post #2149898 by 361.xj9@social.sunshinegardens.org
2018-12-21T01:44:17.198983Z
1 likes, 0 repeats
@Are0h @chucker @jalcine2017-03-01 20.09.58.jpg
(DIR) Post #2156363 by mariusor@metalhead.club
2018-12-20T20:33:16Z
0 likes, 0 repeats
@jalcine Why not QSettings?
(DIR) Post #2156364 by jalcine@playvicious.social
2018-12-20T20:36:23Z
1 likes, 0 repeats
@mariusor this is for a web-based project! I'll 100% be using QSettings for ActivityDesk
(DIR) Post #2156397 by gamehawk@mastodon.social
2018-12-20T21:09:22Z
0 likes, 0 repeats
@jalcine RDF! <ducks><runs away>
(DIR) Post #2156398 by jalcine@playvicious.social
2018-12-20T21:11:19Z
1 likes, 0 repeats
@gamehawk lol! no lie I'm tempted to use it or some XML-esque thing for it. I saw that Wordpress uses it for their themes too
(DIR) Post #2156410 by ThreddyTheTrex@threddy.social
2018-12-20T21:16:32Z
1 likes, 0 repeats
@jalcine I like CSV because I’ve been using R for a few years and everything seems tabular to me now.
(DIR) Post #2156417 by Gargron@mastodon.social
2018-12-20T21:13:11Z
0 likes, 0 repeats
@jalcine I'm using YAML in Mastodon, but it's got some drawbacks, such as autocasting some keys to values, e.g. you need to quote the key "no" because otherwise it turns into boolean false. Toml is what I use in Hugo and it seems very simple and very nice. It's close to ini but I think a bit more capable.
(DIR) Post #2156418 by jalcine@playvicious.social
2018-12-20T21:15:38Z
0 likes, 0 repeats
@Gargron I'm kinda torn now between YAML and JSON. I think I might include some tool to take it from YAML to JSON (because I just need it in that format once - closer to the structs used in Elixir).
(DIR) Post #2156419 by Gargron@mastodon.social
2018-12-20T21:18:27Z
1 likes, 0 repeats
@jalcine If you're aiming for end-user comfort, YAML ranks over JSON. It's easy to break JSON if you don't quote a key, or leave a comma in the wrong place. YAML is simpler.
(DIR) Post #2156430 by jalcine@playvicious.social
2018-12-20T20:42:29Z
0 likes, 0 repeats
I think I'm going to opt for JSON for this project. It's already in the code so no new dependencies. The only thing I might want to add is JSON Schema to do validating but it's not that big of a deal (yet).
(DIR) Post #2156431 by sikkdays@ourempty.pub
2018-12-20T20:49:14Z
0 likes, 0 repeats
@jalcine I feel like I had to dig into JSON for a project or two as a non dev and got the gist of it enough to make my changes. I have a site or two using YAML right now and I still don't get that.
(DIR) Post #2156432 by jalcine@playvicious.social
2018-12-20T20:51:19Z
0 likes, 0 repeats
@sikkdays interesting! I wonder if there's something about the layout of YAML that makes it alien!I had better terms with YAML than with JSON but that's probably because of the amount of linters I have in my editors to catch mistakes
(DIR) Post #2156433 by sikkdays@ourempty.pub
2018-12-20T21:28:40Z
1 likes, 0 repeats
@jalcine I'm just overwhelmed with how YAML integrates with template files and others to create a base for pages in the CMS I started playing with fire my art blog-- Grav. On the whole it is interesting because it can be used by smart folks minus a GUI, or you can get an admin backend and even a more powerful plugin to make visual changes. Being in-between layman and smarty, I get lost. Heh.