-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enhancement: build JSON files and HTML files for the web site #4
Comments
You know what's REALLY cool about this one? We can use OUR json parser Now I will reply to the rest of the comment next (perhaps in between replying to other comments as well). |
Oh and please assign the rest of the issues to me as I reply to them (since I know I have to reply first). |
It does not need an
On this note: would you please (this goes with the other issues) let me know if you updated an issue so that I know to look at it lest I do a major change (as these ARE major) and find out it's no longer valid? It's quite easy to get so involved that one does not think about this (and I often don't think about it anyway esp as our threads do get long with lots to discuss - which is good and I bet you think that it would be better if development was more like that ... I do anyway).
So they should be a dot file then?
Do we need a
That makes sense yes.
You refer to the MANIFEST file in each year's directory, right ?
Something tells me that some of this can be automated ... that would be helpful for sure.
Okay indeed I can think that at least some of this can be generated. If the author wins more than one entry in a year the dir name would be like usual but what about entry name? Just add the number of the entry (for the winner) to the entry_name ?
In other words for 2020 my entries:
which might become:
Right ?
I might just be too tired to process this now. What array do you refer to? Which
Sounds good.
Good idea to come up with a template.
Now this is for the contest as a whole (more than one year) or just each year? Is it an idea to have one for both?
Okay yes I'm afraid I might just be too tired to parse this right now :( I'll try continuing this but I might have to resume the rest of it later.
Above the years I gather?
Good idea with a template here too.
Any idea how to deal with this information? I actually wonder if there's a sql to json tool out there but if not any recommended tools to look at it under macOS? |
I've tried to use the sql file and get errors ... was able to fix some but I don't know enough of sql to fix them all. Going afk for a while .. maybe can work on some of this later but until the issue of not being able to fork this repo (instead of winner) I'm not sure how much good it'll do. |
Of course in my then still tired head I was sillily thinking of the database itself which would make no sense at all. It's the commands which I see you also say. Nevertheless at least in some systems it seems to have syntax errors. It also seems to with converters I found. I haven't tried the sqlite file though. I want to do a bit more before my zoom meeting but my hands are so cold that it's difficult to type (I don't get cold that easily generally except for my extremities which are very often cold). Anyway I have a zoom meeting at the hour and shortly after that I'll probably leave for the day. Hopefully tomorrow I can do a bit more and maybe we can work out the problem of not being able to clone this repo. If you do have to recreate the repo please keep this one here so we can go back for details I the four issues. Of course tomorrow I need to do some other things that I'm not looking forward to but it's for good reasons and they need to be done anyway. Still I should be able to look at some of this and hopefully with a clearer head. Was a pretty rough night. |
If the SQL files are not directly usable, one my be able to extract the text from the SQL directives in order to build the individual JSON files. We effectively need to split up the SQL data into individual chunks: some for people who won, some for the each winning entry. |
I think this will be helpful. I also think it might be possible to write a rudimentary C tool that does it. I will reply to all the comments tomorrow. |
That was the idea for the general parser. We will create our own style of |
Makes sense (the first part) - and I recall something like this as well. And the second part sounds like a good idea too. As for taking the sql file and turning it into json files I have some ideas. Mostly a hack (or perhaps hacks depending on the number of ways). I'm afraid I still am not clear on everything though so I won't really be doing anything of it today. Even so I hope I can do more tomorrow. I think I finally have the other issue resolved - until the domains have transferred. Tomorrow I'll be a bit busy part of the day too - with things that can't be avoided but again for good reasons. Going for the other threads now. |
Done with that .. now as far as templates for the json files. Any ideas what each one should look like? As for the hack I thought of that might allow for generating some of the data from the sql file it would kind of just read the line by pattern (insert into ...) and then parse the data to insert. That part might be more problematic though because json types are different from sql. Database newsI'm not sure what to do about it. Do we need a json file for it? I guess not? Database personThe fact I added an alt url for each author means that we probably need another member presumably alt_url but where that belongs I don't know - I guess the .auth.json file. But that doesn't resolve the fact that we need a template for each one. The persons database would of course end up being an array of authors - unless it's meant to be for each entry and not an entire list? What is needed? Database mirrorsThe mirrors it's suggested you don't do that now. But: INSERT INTO mirrors VALUES(7,'Extraterrestrial','<A HREF="http://www.seti.org">SETI</A> is looking for some sites :-)','','',NULL,NULL,NULL,NULL,1);
is hilarious! Though I am very against trying to find life on other planets as we would just destroy it - just as we would destroy other planets if we went there and I don't think we have that right (not that that would ever stop humans). Still it's a hilarious thought so thank you for the laugh there! Database judgesThe judges one is easy enough once we know what information to include but I'm not sure what file it should be in nor am I sure if we want specific information not there (as noted). Obviously I would have to only have you and Leo. Database yearAs far as years go I guess it would be an array of something like (with the names of the members chosen arbitrarily): "year": 2020,
"contest_number": 27
"name" : "...", Or should the contest number be a string for e.g. "27th" ? Database winnersAs far as winners I guess this is different from the persons database in that it just is a list of winners and not their information. Is that right? What about the fact that anonymous authorship is no longer allowed? I guess the previous anonymous will just be called Database prizesAs for prizes I guess it's also an array of the different information but it seems like it might be for the list of winning entries - not a yearly basis (even if the year is there). Is that right? Database resourceAs for resource: it seems it'll also have to be an array. It seems like it's a more complicated manifest in the Database alphabet_headersThis is an easy one of course. General questions / thoughtsShould any not be used? Should any be merged? What to do about dead links in any of these? In some cases we might use the Internet Wayback Machine but what if there weren't any captures ? What format / layout (ordering) do we want? And the templates: what should each look like? I guess that's the most important thing. AsideYou might have noticed I went from bottom to top .. I've been known also to read articles backwards with improved reading comprehension. No I can't explain that one. I also read sideways, backwards, diagonally, mirrored and other things as well as being able to (though usually I am too tired to do it) read in blocks and scan pages very very quickly finding information that I need (even if I don't know exactly what I'm looking for). I also open books to where I left off - or where the information is that I'm after. Amongst other things :-) .. definitely some gifts but gifts I love. ... going to do other things now. I can reply later depending on when you reply. Else tomorrow. I hope you got some sleep! I did leave a quick pull request but it unfortunately went to winner.git even though I tried your idea that I thought would actually work. Good day! |
See comment 1421609887 for a suggestion on making progress on this issue. |
The |
The reason why we want to call the per-directory JSON file something that starts with a "." (such as perhaps |
No, that file will likely go away. We refer to some elements in the new per directories JSON file that will contain a manifest similar to how |
Yes. |
Correct. |
The author handle will be for the contest as a whole. It is why we ask people submitting new entries if they've won before and if so, what is their handle. This will help us match up a new winning entry with somebody who is previously one so we can add their new win into the list of their previous winners. |
We don't know. If we were to have to do it, we would take the SQL commands and use an editor to turn the appropriate text into stuff we want for JSON file. There may be a better way to do this and you're attempting to do something with the SQL commands or the SQL database might be more useful. It depends on how comfortable you are in working with SQL database. |
We believe we have addressed all of the current questions that still need answering at this time. If we've missed something or something else needs to be clarified, please ask again. |
I'm not yet clear on how that comment will help this one unless you mean that solving this issue will simplify that one. Mind clarifying? |
Okay. So I guess we should figure out what they should contain then (which I guess is part of the template suggestion). |
Right. That makes sense. Thanks for the reminder. Does this apply to all json files? And will there be any other dot files ? |
Ah. Well that's good that there aren't that many then. Also that might change some of at least one of my comments in another thread. |
On that note the issue that decides on terms has to be done before #3 can be completed. Nevertheless next week (not tomorrow but hopefully the following days though who knows with the issue I noted yesterday) I hope to address the other things that can be addressed. |
As noted the 1984 tarball no longer shows any warnings in macOS. So that issue is resolved too though I don't know that you addressed it. I do wonder what happened .. pretty strange thing. Oh well though: it's resolved now (not that I think it was even a problem). Afk now .. I guess I might have replied to everything after all but when back I'll check. If not I'll try replying otherwise go on to my things. Might do some pull requests today but I might not: undecided yet. |
QUESTION about updating entries for issue 3Is there a command I should run whenever I update an entry? For instance earlier today I updated the try script of 2012/konno and the other day I added a try script to 1995/leo. What should I do to regenerate the tarballs? I'm sure you said already or it's in the log but it'd be helpful if you give a quick command here. It might also help if there was a command that does it for every entry. I see a command above for the year level tarballs but then you disabled the www rule from creating the entry tarballs I think. Please advise when you get a chance. I won't be doing anything else today. Hope all is okay! |
The manifest needs to be updated if files are added or renamed or removed. The Followed by a commit and push of course.
With commit 4cb0de8 the make files do NOT rebuild tarballs. We need issue #3 and other mass edits to be finished before we can consider updating tarballs as doing so not would produce needless edits of binary compressed tar blobs.
Best wishes. |
Yes. It definitely needs to be updated again. I will see if I can do that tomorrow. That was my plan but the week has been so exhausting it might be pushed out a bit longer.
Thanks.
Yes. That was my reason for asking. But you make a valid point below.
Good point. And in order for #3 to be done another one has to be done too - the finalising terms. I guess we kind of paused that (not intentionally but did anyway). I'll see if I can get to that in the next day or two. That will help move #3 along.
Thanks. It was a fine day. Got new shoes (I have terrible feet) at an ocean town which was the closest place that has such a shoe shop (Birkenstock shoes). These might actually work for me as they mould to the feet (one foot is flat and another is arched and I have other worse problems even besides that). I had these new ones on longer than I have ever been able to have new shoes on without my feet in agony. Will take time to wear them in but might be in luck. Hopefully tomorrow or the next few days I'll be able to do more. I'd also like to work on the main computer and either salvage it or reinstall it. That's a lower priority however. |
With commit 09b8de5 exit code use in bin scripts has been improved. |
Thanks for the note. Do you want me to do similar (make consistent) with the update status.json script ? As far as what I have planned here today: I'm going to update the manifest if nothing else today. I'm afraid it probably will only be that or if I do anything else it won't be much more. Not this moment. I have something I should go do but after that I hope to do it. |
.. actually I will not be updating the manifest until a pending problem is resolved. Or question. I'll ask it in the respective issue. |
That is not needed at this point as the JSON format has not been finalized, the script is not integrated into the other tools (no need), not a priority for this issue, and may need to be addressed in a new issue that we are working on forming |
With commit aa70cf8 a number of the TODO items have been completed! The power of the md2html configuration file driven architecture is proving its worth. :-) |
Well when you do open it please let me know as I'd like to change the script (as I wrote it) to fit the new format (or whatever else). Then when I reply you can assign it to me. I presume we'll have to discuss things first of course. |
Sounds good! |
Interesting: $ tar ft archive-2004.tar.bz2 2>&1|grep 'tar: Ignor'
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.quarantine'
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.quarantine'
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.quarantine'
tar: Ignoring unknown extended header keyword 'LIBARCHIVE.xattr.com.apple.quarantine'
[...] many more of those. I presume you don't see it. I wonder what it's about. More specifically I wonder why one of the tarballs has this and the others don't. It was the only one that does it. It created another file too: UPDATE 0Exists in rocky linux too. |
With commit 9d3438f the missing HTML files entries (HTML files that |
The macports version of GNU tar is not macOS aware. For some reason the macports GNU tar is not build for macOS.
The rocky linux, tar on the other hand is correct in issuing warnings about attributes that are common to macOS and that do not apply to rocky linux. With commit 21c3e89 the warnings seen by rocky linux and the macports mis-featured GNU tar should hopefully be gone. Please check, @xexyl. Thank you. |
It does not work right in the archive/historic directory, no. Not in macOS and not rocky linux either. You're right though. |
I see that. Thanks! It will help out with working on the manifest too. Actually was it updated? Ah yes. I see that it was. Thanks! I hope I replied to everything but if not I'll probably see it tomorrow .. or later today maybe. Not sure. What I am sure of is I need to do something that doesn't take thinking and preferably laugh. |
With commit 0f8a0a3 ALL HTML FILES that need to be constructed from markdown data and/or JSON files are being built by bin tools! Of course, the content of such markdown files needs to be improved. And for formatting of HTML files has become much more important. See issue #2006. As this issue #4 winds down to a close, issue #2006 has now become a ((top priority)). |
Made a couple typo fixes but noticed something I'm not sure about ... # Obfuscate defined:
tr.v. -cated, -cating, -cates.
<BR><BR>
**1a.** To render obscure.<BR>
**1b.** To darken. But this leaves out the word. One might say it's the section / heading title but it seems not the right way to do about it. But I also can't figure out (now or not I do not know) what |
I think it's a very good idea to do this too. |
Thanks! For the taking care of it and also the note about the other issue. Of course other html files should also be checked. That is the ones that are rendered by markdown files - those that are provided by the author shouldn't be touched, of course. |
With commit 2b92c89, more TODO items has been completed. |
Nice. |
Moved the few of the remaining TODOs to issue #2239. As a result this issue is now complete! |
Whee! I presume though that it would be good for me to still go through many if not all index.html files. Is that correct? But then that issue is open so I guess I don't even need to ask: but I only thought of that after writing this and don't feel like deleting it in iOS. |
Correct. The ones with: <!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<!-- !!! DO NOT MODIFY THIS FILE - This file is generated by a tool !!! -->
<!-- !!! DO NOT MODIFY THIS FILE - This file is generated by a tool !!! -->
<!-- !!! DO NOT MODIFY THIS FILE - This file is generated by a tool !!! -->
<!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> were generated by some tool from an markdown file. QUESTIONShould the comment: <!-- The original markdown content was formed by the tool: bin/gen-top-html.sh -->
<!-- The HTML was converted from markdown by the tool: bin/md2html.sh --> be extended to also mention the markdown file from which it was formed? |
Scope - About this issue
Every winning directory needs a JSON file that describes the winning YYYY/dir entry.
NOTE: This writeup is subject to changes and revisions as the understanding of this issue evolves / improves. Check back to this note from time to time. When modification are made to this comment, we will try to add a note indicating that the scope of this issue has been updated.
TODO
Write a tool to generate
.entry.json
for each YYYY/dir entry.Remove
.id
files when.entry.json
is readyWrite a tool to create
.inventory.md
filesOnce the manifest is stable, write a tool to generate
.inventory.md
files to hold links to all files in the winner directory..inventory.html
from.inventory.md
NOTE: This issue is now obsolete as the inventory is now at the bottom of the YYYY/dir entry
index.html
files..inventory.html
file toinventory.html
NOTE: See "UPDATE 2a" in comment 1793681758.
NOTE: This issue is now obsolete as the inventory is now at the bottom of the YYYY/dir entry
index.html
files.See comment 1893176110.
ioccc.css
NOTE: Using the existing
2020/ferguson1/index.html
as an example, improve the look and feel of rendered HTML.NOTE: Improving does not mean making it perfect, just fixing a few the more glaring problems with the look and feel of rendered HTML.
See comment 1894666815.
See issue #1933 .
NOTE: In
tmp/manifest.numbers
, improve the inventory_order, display_as, display_via_github, and winners_text fields.NOTE: Build the other needed files under
/tmp
after exporting the CSV version (tmp/manifest.csv
) oftmp/manifest.numbers
NOTE: Make adjustments to the manifest as per recent file changes.
NOTE: Update all
.winner.json
files as per the updated manifest.Write a new tool to generate the new top level
location.html
Write a new tool to generate YYYY/dir entry
index.html
files from YYYY/dir entryREADME.md
and.entry.json
filesWrite a new tool to re-generate top level
winners.html
NOTE: The file is now
authors.html
andwinners.html
does a redirect towinners.html
.Write a new tool to re-generate top level
years.html
Write a new tool to generate year level
index.html
files from YYYY/dir entryREADME.md
and.year
filesWrite a new tool to create the bzip2 tarball for each YYYY/dir entry
Write a new tool to create the bzip2 tarball for the winners of each year.
Write a new tool to create the bzip2 tarball for all entries.
Write a new tool to generate the new top level
thanks-for-help.html
fromthanks-for-help.md
Write a new tool to generate the new top level
CODE_OF_CONDUCT.html
fromCODE_OF_CONDUCT.md
Write a new tool to generate the new top level
bugs.html
from the existingbugs.md
Write a new tool to generate the new top level
README.html
from the existing top levelREADME.md
Write a new tool to generate the top level
faq.html
from the existingfaq.md
Write a new tool to generate the top level
thanks-for-help.html
from the existingthanks-for-help.md
Write a new tool to generate the top level
contact.html
from the existingcontact.md
Write a new tool to generate the new top level
judges.html
from a newjudges.md
Write a new tool to generate the new top level
news.html
from a newnews.md
Write a new tool to generate the top level
index.html
from a newindex.md
Write a new tool to generate other winner level HTML files from YYYY/dir entry markdown files
NOTE: This deals with winner files other than YYYY/dir entry
index.html
and YYYY/dir entryREADME.md
files.sitemap.xml
fileSee Sitemaps on Wikipedia.
NOTE: Add to the top level Makefile, special rules to help drive the process to generate all of the above mentioned HTML files and JSON files for the entire site.
NOTE: This TODO item was moved to issue #2007
Near Final TODO
When all HTML files exist, it is time to change all eferences and links from "foo.md" to "foo.html".
The text was updated successfully, but these errors were encountered: