Thanks, Jermey. I'm not quite to node.js yet. I installed but don't really get it. I don't do much at command line.
As for CSV, the tool I'm trying to use (http://www.convertcsv.com/csv-to-json.htm) offers these options: Use this tool to convert CSV data to JSON. There are 4 types of JSON conversions: - CSV to JSON - array of JSON structures matching your CSV - CSV to Keyed JSON - Structure of JSON with the specified key field as the key value to a structure of the remaining fields - CSV to JSON Array - An array of CSV values where the CSV values are in an array, or [image: New] a structure with column names and data as an array - CSV to JSON Column Array - An array of CSV values where each column of values are in an array Which of these would be best to use to import JSON file? Thanks! //steve. On Thursday, July 9, 2015 at 11:32:25 AM UTC-4, Jeremy Ruston wrote: > > Hi Steve > > Funnily enough, I've been working with some CSV files in my dayjob. I've > got a very noddy little Node.js script that converts CSV files into JSON > files. It's not very polished - eg one has to edit the JS source to tell it > which columns to use. > > But, if you're comfortable with Node.js it might make a good starting > point. If you're interested I can post it to GitHub. > > Best wishes > > Jeremy. > > > On Thu, Jul 9, 2015 at 4:18 PM, stevesuny <stev...@gmail.com <javascript:> > > wrote: > >> >> Reviving an old thread. Am again interested in importing CSV as separate >> tiddlers. >> >> I use google sheets to generate CSV. >> >> I'd like to use http://www.convertcsv.com/csv-to-json.htm to create >> json, but none of the output formats work - when I use the import, the json >> file doesn't return any tiddlers available for import. >> >> Anyone have suggestions or experience with this? Or, alternatives? >> >> Thanks, >> >> //steve. >> >> >> On Friday, April 24, 2015 at 11:15:16 AM UTC-4, Jeremy Ruston wrote: >>> >>> Hi Steve >>> >>> You'll probably have seen the current built-in support for CSV files in >>> TW5: dragging or importing a file results in a single tiddler containing >>> the entire CSV file. There's a special parser for text/csv tiddlers so that >>> the content gets displayed as a nicely formatted HTML table. >>> >>> The approach I favour for making the CSV importing more flexible is >>> actually to add facilities for accessing and manipulating the content of >>> CSV tiddlers, rather than extending the import process itself. I like the >>> idea of maintaining CSV as a native format, not just an import format - we >>> could integrate a JavaScript spreadsheet engine like SocialCalc (see >>> http://tiddlywiki.com/rboue's%20plugins%20for%20TiddlyWiki)/ >>> >>> Adding basic support for referencing rows and cells in CSV tiddlers >>> would be fairly straightforward - it would largely mirror the existing >>> implementation for access to property indexes within data tiddlers (aka >>> JSON tiddlers). I'd be happy to guide anyone interested in working on a >>> pull request. >>> >>> Best wishes >>> >>> Jeremy. >>> >>> >>> On Fri, Apr 24, 2015 at 3:01 PM, stevesuny <stev...@gmail.com> wrote: >>> >>>> Of course, writing out the problems leads to its solution (at least >>>> partially). >>>> >>>> I've discovered that, as promised above, a properly formatted json >>>> file, as: >>>> >>>> [ >>>> {"title":"Tiddler1","text":"This is the text of tiddler >>>> 1","tags":"Tag1 Tag2 [[Tag 3]]"}, >>>> {"title":"Tiddler2","text":"This is the text of tiddler 2, with a >>>> link to [[Tiddler1]]","tags":"Tag1 Tag4"} >>>> ] >>>> >>>> saved as, for example, tiddlers.json >>>> >>>> can then be imported using the "native" import in TW5, and then click >>>> on import, and all tiddlers get created. >>>> >>>> >>>> I'm now working on generating json files from spreadsheet. Here is a >>>> link for a script for google sheets: >>>> >>>> >>>> http://blog.pamelafox.org/2013/06/exporting-google-spreadsheet-as-json.html >>>> >>>> It looks reasonable, and I'll work on it today. >>>> >>>> As always, once discovered, it seems straightforward. Thanks, Jeremy, >>>> for the file structure that you put in a few years ago which got me headed >>>> in the right direction. >>>> >>>> //steve. >>>> >>>> >>>> On Friday, April 24, 2015 at 9:53:43 AM UTC-4, Måns wrote: >>>>> >>>>> +1 >>>>> >>>>> My workflow has been to import csv file to TWc via Eric's >>>>> CreateTiddlersFromCsv and then drop the TWc on a TW5 to import all >>>>> tiddlers >>>>> at once. >>>>> The tedious part is then to click/accept to convert every imported >>>>> tiddler from TW classic format to a TW5 format. >>>>> It is tedious when you have 300+ tiddlers to convert. I guess it >>>>> should be ok with a few tiddlers... >>>>> >>>>> There is an online csv to JSON converter here: >>>>> http://www.convertcsv.com/csv-to-json.htm I haven't tried it out >>>>> yet... >>>>> >>>>> If you drag a correctly formated JSON file on to a TW5 it should >>>>> generate tiddlers.... - again I haven't tried it out. >>>>> >>>>> Good luck - and please tell how it goes. >>>>> >>>>> Cheers Måns Mårtensson >>>>> >>>>> >>>>> Den fredag den 24. april 2015 kl. 15.41.55 UTC+2 skrev stevesuny: >>>>>> >>>>>> Resurrecting an old thread, yet again...I have the same challenge (a >>>>>> spreadsheet file where each line becomes a tiddler, with separate column >>>>>> for title, text, tags, etc.. I need to help students import a large >>>>>> number >>>>>> of tiddlers (5 to 200 or more) that they create through spreadsheet >>>>>> manipulation. In TWClassic on tiddlyspace, we use the Tiddlytools plugin >>>>>> http://tiddlytools.com/#CreateTiddlersFromCSV. >>>>>> >>>>>> As I contemplate moving classes from TWClassic to TW5, I need to >>>>>> replicate that functionality, for non-technical users. The responses >>>>>> above >>>>>> reference scripts etc. that are beyond my expertise, and certainly that >>>>>> of >>>>>> my students. >>>>>> >>>>>> How do to this in TW5. Maybe I just don't know how to run the >>>>>> load-file command? >>>>>> >>>>>> Thanks! >>>>>> >>>>>> //steve. >>>>>> >>>>>> >>>>>> On Saturday, November 9, 2013 at 4:56:36 PM UTC-5, Arkady Grudzinsky >>>>>> wrote: >>>>>>> >>>>>>> I have a text file where each line is a list item. I would like to >>>>>>> import this file in my TW5 and create a separate tiddler for each line. >>>>>>> I >>>>>>> also would like to specify tags and some fields for each tiddler. >>>>>>> >>>>>>> .tid files do not allow multiple tiddlers in one file. >>>>>>> >>>>>>> I thought, HTML would work with something like this >>>>>>> <div title="Tiddler 1" tags="task" start="201311080800" >>>>>>> priority="5">Tiddler 1 text</div> >>>>>>> <div title="Tiddler 2" tags="task" start="201311080800" >>>>>>> priority="6">Tiddler 2 text</div> >>>>>>> etc. >>>>>>> >>>>>>> But it did not work. I get one tiddler with type="text/html" with >>>>>>> file name as a title and this HTML code inside. >>>>>>> >>>>>>> I could, of course, create a Perl or an awk script to produce one >>>>>>> .tid file per line, but it seems like too much effort. >>>>>>> >>>>>>> Any suggestions? >>>>>>> >>>>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "TiddlyWiki" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to tiddlywiki+...@googlegroups.com. >>>> To post to this group, send email to tiddl...@googlegroups.com. >>>> Visit this group at http://groups.google.com/group/tiddlywiki. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/tiddlywiki/54ca5c29-ef5f-40b7-91f2-e749e6bf9078%40googlegroups.com >>>> >>>> <https://groups.google.com/d/msgid/tiddlywiki/54ca5c29-ef5f-40b7-91f2-e749e6bf9078%40googlegroups.com?utm_medium=email&utm_source=footer> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> >>> >>> -- >>> Jeremy Ruston >>> mailto:jeremy...@gmail.com >>> >> > > > -- > Jeremy Ruston > mailto:jeremy...@gmail.com <javascript:> > -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To unsubscribe from this group and stop receiving emails from it, send an email to tiddlywiki+unsubscr...@googlegroups.com. To post to this group, send email to tiddlywiki@googlegroups.com. Visit this group at http://groups.google.com/group/tiddlywiki. To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/e13cc504-fe78-4603-b65c-7f361cb94731%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.