Fossil

Check-in [84804f01]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Cards must appear in a lexical order. Thanks Jan!
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | roy-export
Files: files | file ages | folders
SHA1:84804f01c57404a3cc80f347ed9314cae51d9d32
User & Date: roy.marples 2017-02-13 10:59:03
Context
2017-02-21
21:36
Only strip trailing newline when importing comments. check-in: 0e4bf2ca user: roy.marples tags: roy-export
2017-02-13
10:59
Cards must appear in a lexical order. Thanks Jan! check-in: 84804f01 user: roy.marples tags: roy-export
10:53
Add a --comment option to the tag add subcommand. check-in: 8b4dfae5 user: roy.marples tags: roy-export
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/import.c.

213
214
215
216
217
218
219

220
221
222
223
224
225
226
227
228
229
230
231
** Use data accumulated in gg from a "tag" record to add a new
** control artifact to the BLOB table.
*/
static void finish_tag(void){
  Blob record, cksum;
  if( gg.zDate && gg.zTag && gg.zFrom && gg.zUser ){
    blob_zero(&record);

    blob_appendf(&record, "D %s\n", gg.zDate);
    blob_appendf(&record, "T +sym-%F%F%F %s\n", gimport.zTagPre, gg.zTag,
        gimport.zTagSuf, gg.zFrom);
    blob_appendf(&record, "U %F\n", gg.zUser);
    if( gg.zComment ) blob_appendf(&record, "C %F\n", gg.zComment);
    md5sum_blob(&record, &cksum);
    blob_appendf(&record, "Z %b\n", &cksum);
    fast_insert_content(&record, 0, 0, 1);
    blob_reset(&cksum);
  }
  import_reset(0);
}







>




<







213
214
215
216
217
218
219
220
221
222
223
224

225
226
227
228
229
230
231
** Use data accumulated in gg from a "tag" record to add a new
** control artifact to the BLOB table.
*/
static void finish_tag(void){
  Blob record, cksum;
  if( gg.zDate && gg.zTag && gg.zFrom && gg.zUser ){
    blob_zero(&record);
    if( gg.zComment ) blob_appendf(&record, "C %F\n", gg.zComment);
    blob_appendf(&record, "D %s\n", gg.zDate);
    blob_appendf(&record, "T +sym-%F%F%F %s\n", gimport.zTagPre, gg.zTag,
        gimport.zTagSuf, gg.zFrom);
    blob_appendf(&record, "U %F\n", gg.zUser);

    md5sum_blob(&record, &cksum);
    blob_appendf(&record, "Z %b\n", &cksum);
    fast_insert_content(&record, 0, 0, 1);
    blob_reset(&cksum);
  }
  import_reset(0);
}