ro 4.2.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/Gemfile.lock +57 -10
 - data/LICENSE +1 -1
 - data/MIGRATION.md +320 -0
 - data/README.md +286 -111
 - data/Rakefile +2 -2
 - data/a.yml +60 -0
 - data/bin/ro +10 -0
 - data/lib/ro/_lib.rb +18 -6
 - data/lib/ro/asset.rb +67 -16
 - data/lib/ro/collection.rb +91 -10
 - data/lib/ro/config.rb +4 -0
 - data/lib/ro/error.rb +5 -2
 - data/lib/ro/html.rb +23 -0
 - data/lib/ro/html_safe.rb +143 -0
 - data/lib/ro/methods.rb +95 -38
 - data/lib/ro/migrator.rb +285 -0
 - data/lib/ro/node.rb +128 -45
 - data/lib/ro/path.rb +4 -0
 - data/lib/ro/root.rb +75 -1
 - data/lib/ro/script/migrate.rb +204 -0
 - data/lib/ro/script/server.rb +1 -1
 - data/lib/ro/template.rb +62 -22
 - data/lib/ro/text.rb +120 -0
 - data/lib/ro.rb +5 -0
 - data/public/api/ro/index-1.json +997 -79
 - data/public/api/ro/index.json +997 -79
 - data/public/api/ro/nerd/fastest-possible-embeddings/index.json +90 -0
 - data/public/api/ro/nerd/ima/index.json +49 -0
 - data/public/api/ro/nerd/index/index.json +74 -0
 - data/public/api/ro/nerd/index-1.json +204 -0
 - data/public/api/ro/nerd/index.json +194 -0
 - data/public/api/ro/pages/about/index.json +60 -0
 - data/public/api/ro/pages/contact/index.json +50 -0
 - data/public/api/ro/pages/cv/index.json +49 -0
 - data/public/api/ro/pages/disco/index.json +117 -0
 - data/public/api/ro/pages/index/index.json +30 -0
 - data/public/api/ro/pages/index-1.json +366 -0
 - data/public/api/ro/pages/index.json +356 -0
 - data/public/api/ro/pages/jess/index.json +62 -0
 - data/public/api/ro/pages/now/index.json +43 -0
 - data/public/api/ro/posts/almost-died-in-an-ice-cave/index.json +265 -0
 - data/public/api/ro/posts/facebook-and-global-extremism/index.json +90 -0
 - data/public/api/ro/posts/index-1.json +461 -79
 - data/public/api/ro/posts/index.json +461 -79
 - data/public/api/ro/posts/lemmings-considered-harmful/index.json +49 -0
 - data/public/api/ro/posts/lost-in-the-desert/index.json +49 -0
 - data/public/api/ro/posts/mission/index.json +49 -0
 - data/public/api/ro/posts/return-your-laptop/index.json +61 -0
 - data/public/ro/nerd/fastest-possible-embeddings/assets/giraffe.jpeg +0 -0
 - data/public/ro/nerd/fastest-possible-embeddings/assets/let-me-in.jpg +0 -0
 - data/public/ro/nerd/fastest-possible-embeddings/assets/src/fastembed.js +70 -0
 - data/public/ro/nerd/fastest-possible-embeddings/assets/src/fastembed.rs +68 -0
 - data/public/ro/nerd/fastest-possible-embeddings/assets/terminal.jpg +0 -0
 - data/public/ro/nerd/fastest-possible-embeddings/body.md +266 -0
 - data/public/ro/nerd/fastest-possible-embeddings.yml +7 -0
 - data/public/ro/nerd/ima/assets/og.jpeg +0 -0
 - data/public/ro/nerd/ima/body.md +22 -0
 - data/public/ro/nerd/ima.yml +8 -0
 - data/public/ro/nerd/index/assets/giraffe.jpeg +0 -0
 - data/public/ro/nerd/index/assets/let-me-in.jpg +0 -0
 - data/public/ro/nerd/index/assets/terminal.jpg +0 -0
 - data/public/ro/nerd/index/body.md +130 -0
 - data/public/ro/nerd/index.yml +7 -0
 - data/public/ro/pages/about/assets/og.jpeg +0 -0
 - data/public/ro/pages/about/assets/speak-english-pulp-fiction.gif +0 -0
 - data/public/ro/pages/about/body.md +40 -0
 - data/public/ro/pages/contact/assets/giraffe.jpeg +0 -0
 - data/public/ro/pages/contact/body.md +9 -0
 - data/public/ro/pages/contact.yml +7 -0
 - data/public/ro/pages/cv/assets/ara.jpg +0 -0
 - data/public/ro/pages/cv/body.md +122 -0
 - data/public/ro/pages/cv.yml +6 -0
 - data/public/ro/pages/disco/assets/disco.jpg +0 -0
 - data/public/ro/pages/disco/assets/disco.png +0 -0
 - data/public/ro/pages/disco/assets/speak-english-pulp-fiction.gif +0 -0
 - data/public/ro/pages/disco/assets/src/environment.md +2354 -0
 - data/public/ro/pages/disco/assets/src/fortune-500.md +2518 -0
 - data/public/ro/pages/disco/assets/src/greed.md +2703 -0
 - data/public/ro/pages/disco/assets/src/up-at-night.md +2337 -0
 - data/public/ro/pages/disco/body.md +99 -0
 - data/public/ro/pages/disco/samples/environment.md +2354 -0
 - data/public/ro/pages/disco/samples/fortune-500.md +2518 -0
 - data/public/ro/pages/disco/samples/greed.md +2703 -0
 - data/public/ro/pages/disco/samples/up-at-night.md +2337 -0
 - data/public/ro/pages/disco.yml +9 -0
 - data/public/ro/pages/index/body.md +15 -0
 - data/public/ro/pages/index.yml +1 -0
 - data/public/ro/pages/jess/assets/og.jpg +0 -0
 - data/public/ro/pages/jess/assets/speak-english-pulp-fiction.gif +0 -0
 - data/public/ro/pages/jess/body.md +3 -0
 - data/public/ro/pages/jess.yml +7 -0
 - data/public/ro/pages/now/assets/speak-english-pulp-fiction.gif +0 -0
 - data/public/ro/pages/now/body.md +24 -0
 - data/public/ro/pages/now.yml +1 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image1.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image10.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image11.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image12.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image13.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image14.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image15.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image2.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image3.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image4.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image5.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image6.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image7.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image8.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/image9.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/josh-pointing.jpg +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/levi-rawr.png +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/og.jpg +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/assets/purple-heart.jpg +0 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave/body.md +419 -0
 - data/public/ro/posts/almost-died-in-an-ice-cave.yml +6 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/background.html +125 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/background.md +95 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/og.jpg +0 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/prompt.txt +122 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/results.md +183 -0
 - data/public/ro/posts/facebook-and-global-extremism/assets/survey.txt +190 -0
 - data/public/ro/posts/facebook-and-global-extremism/body.md +393 -0
 - data/public/ro/posts/facebook-and-global-extremism.yml +7 -0
 - data/public/ro/posts/lemmings-considered-harmful/assets/lemming.jpeg +0 -0
 - data/public/ro/posts/lemmings-considered-harmful/body.md +43 -0
 - data/public/ro/posts/lemmings-considered-harmful.yml +6 -0
 - data/public/ro/posts/lost-in-the-desert/assets/og.jpg +0 -0
 - data/public/ro/posts/lost-in-the-desert/body.md +7 -0
 - data/public/ro/posts/lost-in-the-desert.yml +6 -0
 - data/public/ro/posts/mission/assets/og.jpg +0 -0
 - data/public/ro/posts/mission/body.md +4 -0
 - data/public/ro/posts/mission.yml +6 -0
 - data/public/ro/posts/return-your-laptop/assets/og.jpg +0 -0
 - data/public/ro/posts/return-your-laptop/assets/return-your-laptop.png +0 -0
 - data/public/ro/posts/return-your-laptop/body.md +58 -0
 - data/public/ro/posts/return-your-laptop.yml +6 -0
 - data/ro.gemspec +369 -49
 - data/scripts/speedtest.rb +324 -0
 - data/specs/001-simplify-asset-structure/IMPLEMENTATION_SUMMARY.md +212 -0
 - data/specs/001-simplify-asset-structure/checklists/requirements.md +36 -0
 - data/specs/001-simplify-asset-structure/contracts/collection_api.md +407 -0
 - data/specs/001-simplify-asset-structure/contracts/migrator_api.md +461 -0
 - data/specs/001-simplify-asset-structure/contracts/node_api.md +294 -0
 - data/specs/001-simplify-asset-structure/data-model.md +381 -0
 - data/specs/001-simplify-asset-structure/plan.md +90 -0
 - data/specs/001-simplify-asset-structure/quickstart.md +575 -0
 - data/specs/001-simplify-asset-structure/research.md +333 -0
 - data/specs/001-simplify-asset-structure/spec.md +127 -0
 - data/specs/001-simplify-asset-structure/tasks.md +349 -0
 - data/test/fixtures/new_structure/mixed/test-json.json +5 -0
 - data/test/fixtures/new_structure/mixed/test-yaml.yml +3 -0
 - data/test/fixtures/new_structure/posts/metadata-only.yml +7 -0
 - data/test/fixtures/new_structure/posts/nested-test/assets/subdirectory/image.png +2 -0
 - data/test/fixtures/new_structure/posts/nested-test.yml +7 -0
 - data/test/fixtures/new_structure/posts/sample-post/assets/body.md +5 -0
 - data/test/fixtures/new_structure/posts/sample-post/assets/image.jpg +2 -0
 - data/test/fixtures/new_structure/posts/sample-post.yml +7 -0
 - data/test/fixtures/old_structure/posts/assets-only/assets/test.txt +1 -0
 - data/test/fixtures/old_structure/posts/sample-post/assets/body.md +5 -0
 - data/test/fixtures/old_structure/posts/sample-post/assets/image.jpg +2 -0
 - data/test/fixtures/old_structure/posts/sample-post/attributes.yml +2 -0
 - data/test/integration/ro_integration_test.rb +165 -0
 - data/test/test_helper.rb +149 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/migration_test_1760746513/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/migration_test_1760746513/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/migration_test_1760746513/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760746513.backup.20251018001513/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/migration_test_1760746556/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/migration_test_1760746556/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/migration_test_1760746556/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760746556.backup.20251018001556/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/migration_test_1760755248/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/migration_test_1760755248/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/migration_test_1760755248/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/posts/sample-post/attributes.yml +7 -0
 - data/test/tmp/migration_test_1760755248.backup.20251018024048/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/migration_test_1760758803/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/migration_test_1760758803/posts/sample-post/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/migration_test_1760758803/posts/sample-post.yml +7 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/posts/sample-post/body.md +5 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/posts/sample-post/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758803.backup.20251018034003/posts/sample-post.yml +7 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/migration_test_1760758869/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/migration_test_1760758869/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/migration_test_1760758869/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758869.backup.20251018034109/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/migration_test_1760758920/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/migration_test_1760758920/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/migration_test_1760758920/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760758920.backup.20251018034200/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/migration_test_1760824728/posts/assets-only/assets/test.txt +1 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/migration_test_1760824728/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/migration_test_1760824728/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/migration_test_1760824728/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/posts/assets-only/assets/test.txt +1 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760824728.backup.20251018215848/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/migration_test_1760844153/posts/assets-only/assets/test.txt +1 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/migration_test_1760844153/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/migration_test_1760844153/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/migration_test_1760844153/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/posts/assets-only/assets/test.txt +1 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/posts/sample-post/assets/body.md +5 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/posts/sample-post/assets/image.jpg +2 -0
 - data/test/tmp/migration_test_1760844153.backup.20251019032233/posts/sample-post/attributes.yml +2 -0
 - data/test/tmp/new_structure_test_1760746452/mixed/test-json.json +5 -0
 - data/test/tmp/new_structure_test_1760746452/mixed/test-yaml.yml +3 -0
 - data/test/tmp/new_structure_test_1760746452/posts/metadata-only.yml +7 -0
 - data/test/tmp/new_structure_test_1760746452/posts/nested-test/subdirectory/image.png +2 -0
 - data/test/tmp/new_structure_test_1760746452/posts/nested-test.yml +7 -0
 - data/test/tmp/new_structure_test_1760746452/posts/sample-post/body.md +5 -0
 - data/test/tmp/new_structure_test_1760746452/posts/sample-post/image.jpg +2 -0
 - data/test/tmp/new_structure_test_1760746452/posts/sample-post.yml +7 -0
 - data/test/unit/asset_test.rb +90 -0
 - data/test/unit/collection_test.rb +127 -0
 - data/test/unit/migrator_test.rb +209 -0
 - data/test/unit/node_test.rb +138 -0
 - data/tmp/gem-details.oe +0 -0
 - metadata +250 -33
 - data/public/api/ro/posts/first_post/index.json +0 -52
 - data/public/api/ro/posts/second_post/index.json +0 -51
 - data/public/api/ro/posts/third_post/index.json +0 -51
 - data/public/ro/posts/first_post/assets/foo/bar/baz.jpg +0 -0
 - data/public/ro/posts/first_post/assets/foo.jpg +0 -0
 - data/public/ro/posts/first_post/assets/src/foo/bar.rb +0 -3
 - data/public/ro/posts/first_post/attributes.yml +0 -2
 - data/public/ro/posts/first_post/blurb.erb.md +0 -7
 - data/public/ro/posts/first_post/body.md +0 -16
 - data/public/ro/posts/first_post/testing.txt +0 -3
 - data/public/ro/posts/second_post/assets/foo/bar/baz.jpg +0 -0
 - data/public/ro/posts/second_post/assets/foo.jpg +0 -0
 - data/public/ro/posts/second_post/assets/src/foo/bar.rb +0 -3
 - data/public/ro/posts/second_post/attributes.yml +0 -2
 - data/public/ro/posts/second_post/blurb.erb.md +0 -5
 - data/public/ro/posts/second_post/body.md +0 -16
 - data/public/ro/posts/third_post/assets/foo/bar/baz.jpg +0 -0
 - data/public/ro/posts/third_post/assets/foo.jpg +0 -0
 - data/public/ro/posts/third_post/assets/src/foo/bar.rb +0 -3
 - data/public/ro/posts/third_post/attributes.yml +0 -2
 - data/public/ro/posts/third_post/blurb.erb.md +0 -5
 - data/public/ro/posts/third_post/body.md +0 -16
 
| 
         @@ -0,0 +1,324 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            require 'fileutils'
         
     | 
| 
      
 2 
     | 
    
         
            +
             
     | 
| 
      
 3 
     | 
    
         
            +
            md = DATA.read
         
     | 
| 
      
 4 
     | 
    
         
            +
             
     | 
| 
      
 5 
     | 
    
         
            +
            unless test(?d, './public/ro/speedtest')
         
     | 
| 
      
 6 
     | 
    
         
            +
              FileUtils.mkdir_p('./public/ro/speedtest/')
         
     | 
| 
      
 7 
     | 
    
         
            +
             
     | 
| 
      
 8 
     | 
    
         
            +
              1000.times do |i|
         
     | 
| 
      
 9 
     | 
    
         
            +
                FileUtils.mkdir_p "./public/ro/speedtest/#{ i }"
         
     | 
| 
      
 10 
     | 
    
         
            +
                IO.binwrite "./public/ro/speedtest/#{ i }/body.md", md
         
     | 
| 
      
 11 
     | 
    
         
            +
              end
         
     | 
| 
      
 12 
     | 
    
         
            +
            end
         
     | 
| 
      
 13 
     | 
    
         
            +
             
     | 
| 
      
 14 
     | 
    
         
            +
            require_relative './lib/ro'
         
     | 
| 
      
 15 
     | 
    
         
            +
             
     | 
| 
      
 16 
     | 
    
         
            +
            a = Time.now.to_f
         
     | 
| 
      
 17 
     | 
    
         
            +
             
     | 
| 
      
 18 
     | 
    
         
            +
            ro = Ro.root
         
     | 
| 
      
 19 
     | 
    
         
            +
             
     | 
| 
      
 20 
     | 
    
         
            +
            ro.posts.each(&:attributes)
         
     | 
| 
      
 21 
     | 
    
         
            +
            ro.speedtest.each(&:attributes)
         
     | 
| 
      
 22 
     | 
    
         
            +
             
     | 
| 
      
 23 
     | 
    
         
            +
            b = Time.now.to_f
         
     | 
| 
      
 24 
     | 
    
         
            +
             
     | 
| 
      
 25 
     | 
    
         
            +
            puts((b - a).round(2))
         
     | 
| 
      
 26 
     | 
    
         
            +
             
     | 
| 
      
 27 
     | 
    
         
            +
            __END__
         
     | 
| 
      
 28 
     | 
    
         
            +
             
     | 
| 
      
 29 
     | 
    
         
            +
            # GitHub Markdown Kitchen Sink
         
     | 
| 
      
 30 
     | 
    
         
            +
             
     | 
| 
      
 31 
     | 
    
         
            +
            A large collection of code samples which have been tested against GitHub's markdown parser... so you don't have to.
         
     | 
| 
      
 32 
     | 
    
         
            +
             
     | 
| 
      
 33 
     | 
    
         
            +
            #### Resources
         
     | 
| 
      
 34 
     | 
    
         
            +
             
     | 
| 
      
 35 
     | 
    
         
            +
            ##### This Repo
         
     | 
| 
      
 36 
     | 
    
         
            +
             
     | 
| 
      
 37 
     | 
    
         
            +
            - README.md ([preview](https://github.com/adamschwartz/github-markdown-kitchen-sink/blob/master/README.md), [raw](https://raw.github.com/adamschwartz/github-markdown-kitchen-sink/master/README.md)) – this file
         
     | 
| 
      
 38 
     | 
    
         
            +
            - TEST.md ([preview](https://github.com/adamschwartz/github-markdown-kitchen-sink/blob/master/TEST.md), [raw](https://raw.github.com/adamschwartz/github-markdown-kitchen-sink/master/TEST.md)) — used to test the examples from this file, which are pre-generated
         
     | 
| 
      
 39 
     | 
    
         
            +
             
     | 
| 
      
 40 
     | 
    
         
            +
            ##### Markdown
         
     | 
| 
      
 41 
     | 
    
         
            +
             
     | 
| 
      
 42 
     | 
    
         
            +
            - [Original Markdown Syntax](http://daringfireball.net/projects/markdown/syntax) from John Gruber
         
     | 
| 
      
 43 
     | 
    
         
            +
            - [GitHub-Flavored Markdown](https://help.github.com/articles/github-flavored-markdown) from GitHub
         
     | 
| 
      
 44 
     | 
    
         
            +
             
     | 
| 
      
 45 
     | 
    
         
            +
            ## Code Examples with Preview
         
     | 
| 
      
 46 
     | 
    
         
            +
             
     | 
| 
      
 47 
     | 
    
         
            +
            ### Block Elements
         
     | 
| 
      
 48 
     | 
    
         
            +
             
     | 
| 
      
 49 
     | 
    
         
            +
            <table>
         
     | 
| 
      
 50 
     | 
    
         
            +
              <tr><td>Code</td><td>Preview</td></tr>
         
     | 
| 
      
 51 
     | 
    
         
            +
             
     | 
| 
      
 52 
     | 
    
         
            +
              <!--- Paragraphs -->
         
     | 
| 
      
 53 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 54 
     | 
    
         
            +
                <td colspan="2">Paragraph</td>
         
     | 
| 
      
 55 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 56 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 57 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 58 
     | 
    
         
            +
                  <pre><code>This is a paragraph.</code></pre>
         
     | 
| 
      
 59 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 60 
     | 
    
         
            +
                <td>This is a paragraph.</td>
         
     | 
| 
      
 61 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 62 
     | 
    
         
            +
             
     | 
| 
      
 63 
     | 
    
         
            +
              <!--- Headers -->
         
     | 
| 
      
 64 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 65 
     | 
    
         
            +
                <td colspan="2">Headers (Sextext-style)</td>
         
     | 
| 
      
 66 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 67 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 68 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 69 
     | 
    
         
            +
            <pre><code>Header 1
         
     | 
| 
      
 70 
     | 
    
         
            +
            ========
         
     | 
| 
      
 71 
     | 
    
         
            +
             
     | 
| 
      
 72 
     | 
    
         
            +
            Header 2
         
     | 
| 
      
 73 
     | 
    
         
            +
            --------</code></pre>
         
     | 
| 
      
 74 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 75 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 76 
     | 
    
         
            +
                  <h1>Header 1</h1>
         
     | 
| 
      
 77 
     | 
    
         
            +
                  <h2>Header 2</h2>
         
     | 
| 
      
 78 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 79 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 80 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 81 
     | 
    
         
            +
                <td colspan="2">Headers (Atx-style)</td>
         
     | 
| 
      
 82 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 83 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 84 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 85 
     | 
    
         
            +
            <pre><code># Header 1
         
     | 
| 
      
 86 
     | 
    
         
            +
            ## Header 2
         
     | 
| 
      
 87 
     | 
    
         
            +
            ### Header 3
         
     | 
| 
      
 88 
     | 
    
         
            +
            #### Header 4
         
     | 
| 
      
 89 
     | 
    
         
            +
            ##### Header 5
         
     | 
| 
      
 90 
     | 
    
         
            +
            ###### Header 6</code></pre>
         
     | 
| 
      
 91 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 92 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 93 
     | 
    
         
            +
                  <h1>Header 1</h1>
         
     | 
| 
      
 94 
     | 
    
         
            +
                  <h2>Header 2</h2>
         
     | 
| 
      
 95 
     | 
    
         
            +
                  <h3>Header 3</h3>
         
     | 
| 
      
 96 
     | 
    
         
            +
                  <h4>Header 4</h4>
         
     | 
| 
      
 97 
     | 
    
         
            +
                  <h5>Header 5</h5>
         
     | 
| 
      
 98 
     | 
    
         
            +
                  <h6>Header 6</h6>
         
     | 
| 
      
 99 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 100 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 101 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 102 
     | 
    
         
            +
                <td colspan="2">Headers (Atx-style closed)</td>
         
     | 
| 
      
 103 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 104 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 105 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 106 
     | 
    
         
            +
            <pre><code># Header 1 #
         
     | 
| 
      
 107 
     | 
    
         
            +
            ## Header 2 ##
         
     | 
| 
      
 108 
     | 
    
         
            +
            ### Header 3 ###
         
     | 
| 
      
 109 
     | 
    
         
            +
            #### Header 4 ####
         
     | 
| 
      
 110 
     | 
    
         
            +
            ##### Header 5 #####
         
     | 
| 
      
 111 
     | 
    
         
            +
            ###### Header 6 #####</code></pre>
         
     | 
| 
      
 112 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 113 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 114 
     | 
    
         
            +
                  <h1>Header 1</h1>
         
     | 
| 
      
 115 
     | 
    
         
            +
                  <h2>Header 2</h2>
         
     | 
| 
      
 116 
     | 
    
         
            +
                  <h3>Header 3</h3>
         
     | 
| 
      
 117 
     | 
    
         
            +
                  <h4>Header 4</h4>
         
     | 
| 
      
 118 
     | 
    
         
            +
                  <h5>Header 5</h5>
         
     | 
| 
      
 119 
     | 
    
         
            +
                  <h6>Header 6</h6>
         
     | 
| 
      
 120 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 121 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 122 
     | 
    
         
            +
             
     | 
| 
      
 123 
     | 
    
         
            +
              <!--- Blockquotes -->
         
     | 
| 
      
 124 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 125 
     | 
    
         
            +
                <td colspan="2">Blockquote</td>
         
     | 
| 
      
 126 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 127 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 128 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 129 
     | 
    
         
            +
                  <pre><code>> Lorem ipsum dolor sit amet [...]</code></pre>
         
     | 
| 
      
 130 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 131 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 132 
     | 
    
         
            +
                  <blockquote>
         
     | 
| 
      
 133 
     | 
    
         
            +
                    Lorem ipsum dolor sit amet, consectetuer adipiscing elit.
         
     | 
| 
      
 134 
     | 
    
         
            +
                    Aliquam hendrerit mi posuere lectus. Vestibulum enim wisi,
         
     | 
| 
      
 135 
     | 
    
         
            +
                    viverra nec, fringilla in, laoreet vitae, risus.
         
     | 
| 
      
 136 
     | 
    
         
            +
                  </blockquote>
         
     | 
| 
      
 137 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 138 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 139 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 140 
     | 
    
         
            +
                <td colspan="2">Blockquote with nested elements</td>
         
     | 
| 
      
 141 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 142 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 143 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 144 
     | 
    
         
            +
                  <!--- Code exmaple -->
         
     | 
| 
      
 145 
     | 
    
         
            +
                  <pre><code>> ## This is a header.
         
     | 
| 
      
 146 
     | 
    
         
            +
            > 1. This is the first list item.
         
     | 
| 
      
 147 
     | 
    
         
            +
            > 2. This is the second list item.
         
     | 
| 
      
 148 
     | 
    
         
            +
            >
         
     | 
| 
      
 149 
     | 
    
         
            +
            > Here's some example code:
         
     | 
| 
      
 150 
     | 
    
         
            +
            >
         
     | 
| 
      
 151 
     | 
    
         
            +
            >     Markdown.generate();</code></pre>
         
     | 
| 
      
 152 
     | 
    
         
            +
                  <!--- End code exmaple -->
         
     | 
| 
      
 153 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 154 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 155 
     | 
    
         
            +
                  <blockquote>
         
     | 
| 
      
 156 
     | 
    
         
            +
                    <h2>This is a header.</h2>
         
     | 
| 
      
 157 
     | 
    
         
            +
                      <ol>
         
     | 
| 
      
 158 
     | 
    
         
            +
                        <li>This is the first list item.</li>
         
     | 
| 
      
 159 
     | 
    
         
            +
                        <li>This is the second list item.</li>
         
     | 
| 
      
 160 
     | 
    
         
            +
                      </ol>
         
     | 
| 
      
 161 
     | 
    
         
            +
                      <p>Here's some example code:</p>
         
     | 
| 
      
 162 
     | 
    
         
            +
                      <pre><code>Markdown.generate();</code></pre>
         
     | 
| 
      
 163 
     | 
    
         
            +
                  </blockquote>
         
     | 
| 
      
 164 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 165 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 166 
     | 
    
         
            +
             
     | 
| 
      
 167 
     | 
    
         
            +
              <!--- Lists -->
         
     | 
| 
      
 168 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 169 
     | 
    
         
            +
                <td colspan="2">List</td>
         
     | 
| 
      
 170 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 171 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 172 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 173 
     | 
    
         
            +
            <table><tr><td>
         
     | 
| 
      
 174 
     | 
    
         
            +
            <pre><code>- Red
         
     | 
| 
      
 175 
     | 
    
         
            +
            - Green
         
     | 
| 
      
 176 
     | 
    
         
            +
            - Blue</code></pre>
         
     | 
| 
      
 177 
     | 
    
         
            +
            </td><td>
         
     | 
| 
      
 178 
     | 
    
         
            +
            <pre><code>+ Red
         
     | 
| 
      
 179 
     | 
    
         
            +
            + Green
         
     | 
| 
      
 180 
     | 
    
         
            +
            + Blue</code></pre>
         
     | 
| 
      
 181 
     | 
    
         
            +
            </td><td>
         
     | 
| 
      
 182 
     | 
    
         
            +
            <pre><code>* Red
         
     | 
| 
      
 183 
     | 
    
         
            +
            * Green
         
     | 
| 
      
 184 
     | 
    
         
            +
            * Blue</code></pre>
         
     | 
| 
      
 185 
     | 
    
         
            +
            </td></tr></table>
         
     | 
| 
      
 186 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 187 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 188 
     | 
    
         
            +
                  <ul>
         
     | 
| 
      
 189 
     | 
    
         
            +
                    <li>Red</li>
         
     | 
| 
      
 190 
     | 
    
         
            +
                    <li>Green</li>
         
     | 
| 
      
 191 
     | 
    
         
            +
                    <li>Blue</li>
         
     | 
| 
      
 192 
     | 
    
         
            +
                  </ul>
         
     | 
| 
      
 193 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 194 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 195 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 196 
     | 
    
         
            +
                <td colspan="2">Ordered List</td>
         
     | 
| 
      
 197 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 198 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 199 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 200 
     | 
    
         
            +
            <pre><code>1. Buy flour and salt
         
     | 
| 
      
 201 
     | 
    
         
            +
            1. Mix together with water
         
     | 
| 
      
 202 
     | 
    
         
            +
            1. Bake</code></pre>
         
     | 
| 
      
 203 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 204 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 205 
     | 
    
         
            +
                  <ol>
         
     | 
| 
      
 206 
     | 
    
         
            +
                    <li>Buy flour and salt</li>
         
     | 
| 
      
 207 
     | 
    
         
            +
                    <li>Mix together with water</li>
         
     | 
| 
      
 208 
     | 
    
         
            +
                    <li>Bake</li>
         
     | 
| 
      
 209 
     | 
    
         
            +
                  </ol>
         
     | 
| 
      
 210 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 211 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 212 
     | 
    
         
            +
             
     | 
| 
      
 213 
     | 
    
         
            +
              <!-- Code blocks -->
         
     | 
| 
      
 214 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 215 
     | 
    
         
            +
                <td colspan="2">Code Block</td>
         
     | 
| 
      
 216 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 217 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 218 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 219 
     | 
    
         
            +
            <pre><code>Normal paragraph.
         
     | 
| 
      
 220 
     | 
    
         
            +
                Code</code></pre>
         
     | 
| 
      
 221 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 222 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 223 
     | 
    
         
            +
                  <p>Normal paragraph.</p>
         
     | 
| 
      
 224 
     | 
    
         
            +
                  <pre><code>Code</code></pre>
         
     | 
| 
      
 225 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 226 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 227 
     | 
    
         
            +
             
     | 
| 
      
 228 
     | 
    
         
            +
              <!-- Horizontal rules -->
         
     | 
| 
      
 229 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 230 
     | 
    
         
            +
                <td colspan="2">Horizontal Rules</td>
         
     | 
| 
      
 231 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 232 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 233 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 234 
     | 
    
         
            +
            <pre><code>* * *
         
     | 
| 
      
 235 
     | 
    
         
            +
             
     | 
| 
      
 236 
     | 
    
         
            +
            ***
         
     | 
| 
      
 237 
     | 
    
         
            +
             
     | 
| 
      
 238 
     | 
    
         
            +
            *****
         
     | 
| 
      
 239 
     | 
    
         
            +
             
     | 
| 
      
 240 
     | 
    
         
            +
            - - -
         
     | 
| 
      
 241 
     | 
    
         
            +
             
     | 
| 
      
 242 
     | 
    
         
            +
            ---------------------------------------</code></pre>
         
     | 
| 
      
 243 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 244 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 245 
     | 
    
         
            +
                  <hr/>
         
     | 
| 
      
 246 
     | 
    
         
            +
                  <hr/>
         
     | 
| 
      
 247 
     | 
    
         
            +
                  <hr/>
         
     | 
| 
      
 248 
     | 
    
         
            +
                  <hr/>
         
     | 
| 
      
 249 
     | 
    
         
            +
                  <hr/>
         
     | 
| 
      
 250 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 251 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 252 
     | 
    
         
            +
            </table>
         
     | 
| 
      
 253 
     | 
    
         
            +
             
     | 
| 
      
 254 
     | 
    
         
            +
            ### Inline Elements
         
     | 
| 
      
 255 
     | 
    
         
            +
             
     | 
| 
      
 256 
     | 
    
         
            +
            <table>
         
     | 
| 
      
 257 
     | 
    
         
            +
              <tr><td>Code</td><td>Preview</td></tr>
         
     | 
| 
      
 258 
     | 
    
         
            +
             
     | 
| 
      
 259 
     | 
    
         
            +
              <!--- Links -->
         
     | 
| 
      
 260 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 261 
     | 
    
         
            +
                <td colspan="2">Links</td>
         
     | 
| 
      
 262 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 263 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 264 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 265 
     | 
    
         
            +
                  <pre><code>This is [an example](http://example.com "Example") link.
         
     | 
| 
      
 266 
     | 
    
         
            +
             
     | 
| 
      
 267 
     | 
    
         
            +
            [This link](http://example.com) has no title attr.
         
     | 
| 
      
 268 
     | 
    
         
            +
             
     | 
| 
      
 269 
     | 
    
         
            +
            This is [an example] [id] reference-style link.
         
     | 
| 
      
 270 
     | 
    
         
            +
             
     | 
| 
      
 271 
     | 
    
         
            +
            [id]: http://example.com "Optional Title"</code></pre>
         
     | 
| 
      
 272 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 273 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 274 
     | 
    
         
            +
                  <p>This is <a href="http://example.com" title="Example">an example</a> link.</p>
         
     | 
| 
      
 275 
     | 
    
         
            +
                  <p><a href="http://example.com">This link</a> has no title attr.</p>
         
     | 
| 
      
 276 
     | 
    
         
            +
                  <p>This is <a href="http://example.com" title="Optional Title">an example</a> reference-style link.</p>
         
     | 
| 
      
 277 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 278 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 279 
     | 
    
         
            +
             
     | 
| 
      
 280 
     | 
    
         
            +
              <!--- Emphasis -->
         
     | 
| 
      
 281 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 282 
     | 
    
         
            +
                <td colspan="2">Emphasis</td>
         
     | 
| 
      
 283 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 284 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 285 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 286 
     | 
    
         
            +
                  <pre><code>*single asterisks*
         
     | 
| 
      
 287 
     | 
    
         
            +
             
     | 
| 
      
 288 
     | 
    
         
            +
            _single underscores_
         
     | 
| 
      
 289 
     | 
    
         
            +
             
     | 
| 
      
 290 
     | 
    
         
            +
            **double asterisks**
         
     | 
| 
      
 291 
     | 
    
         
            +
             
     | 
| 
      
 292 
     | 
    
         
            +
            __double underscores__</td>
         
     | 
| 
      
 293 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 294 
     | 
    
         
            +
                  <p><em>single asterisks</em></p>
         
     | 
| 
      
 295 
     | 
    
         
            +
                  <p><em>single underscores</em></p>
         
     | 
| 
      
 296 
     | 
    
         
            +
                  <p><strong>double asterisks</strong></p>
         
     | 
| 
      
 297 
     | 
    
         
            +
                  <p><strong>double underscores</strong></p>
         
     | 
| 
      
 298 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 299 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 300 
     | 
    
         
            +
             
     | 
| 
      
 301 
     | 
    
         
            +
              <!--- Code -->
         
     | 
| 
      
 302 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 303 
     | 
    
         
            +
                <td colspan="2">Code</td>
         
     | 
| 
      
 304 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 305 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 306 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 307 
     | 
    
         
            +
                  <pre><code>This paragraph has some `code` in it.</td>
         
     | 
| 
      
 308 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 309 
     | 
    
         
            +
                  <p>This paragraph has some <code>code</code> in it.</p>
         
     | 
| 
      
 310 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 311 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 312 
     | 
    
         
            +
             
     | 
| 
      
 313 
     | 
    
         
            +
              <!--- Images -->
         
     | 
| 
      
 314 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 315 
     | 
    
         
            +
                <td colspan="2">Image</td>
         
     | 
| 
      
 316 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 317 
     | 
    
         
            +
              <tr>
         
     | 
| 
      
 318 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 319 
     | 
    
         
            +
                  <pre><code></td>
         
     | 
| 
      
 320 
     | 
    
         
            +
                <td>
         
     | 
| 
      
 321 
     | 
    
         
            +
                  <p><img src="https://get.svg.workers.dev/?s=64&f=gray" title="Image Title" alt="Alt Text" /></p>
         
     | 
| 
      
 322 
     | 
    
         
            +
                </td>
         
     | 
| 
      
 323 
     | 
    
         
            +
              </tr>
         
     | 
| 
      
 324 
     | 
    
         
            +
            </table>
         
     | 
| 
         @@ -0,0 +1,212 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # Ro Asset Structure Simplification - Implementation Summary
         
     | 
| 
      
 2 
     | 
    
         
            +
             
     | 
| 
      
 3 
     | 
    
         
            +
            ## Overview
         
     | 
| 
      
 4 
     | 
    
         
            +
             
     | 
| 
      
 5 
     | 
    
         
            +
            Successfully implemented the simplified asset directory structure for Ro v5.0, reducing nesting depth from 3 to 2 levels and making the codebase more intuitive.
         
     | 
| 
      
 6 
     | 
    
         
            +
             
     | 
| 
      
 7 
     | 
    
         
            +
            ## Implementation Status
         
     | 
| 
      
 8 
     | 
    
         
            +
             
     | 
| 
      
 9 
     | 
    
         
            +
            ### ✅ Completed
         
     | 
| 
      
 10 
     | 
    
         
            +
             
     | 
| 
      
 11 
     | 
    
         
            +
            #### Phase 1: Setup Infrastructure (T001-T005)
         
     | 
| 
      
 12 
     | 
    
         
            +
            - Created comprehensive test infrastructure
         
     | 
| 
      
 13 
     | 
    
         
            +
            - Set up test helper with utilities for fixture management
         
     | 
| 
      
 14 
     | 
    
         
            +
            - Established test patterns and assertions
         
     | 
| 
      
 15 
     | 
    
         
            +
             
     | 
| 
      
 16 
     | 
    
         
            +
            #### Phase 2: Foundational Fixtures (T006-T010)
         
     | 
| 
      
 17 
     | 
    
         
            +
            - Created old structure fixtures for backward compatibility testing
         
     | 
| 
      
 18 
     | 
    
         
            +
            - Created new structure fixtures for new functionality testing
         
     | 
| 
      
 19 
     | 
    
         
            +
            - Set up mixed format fixtures (YAML, JSON)
         
     | 
| 
      
 20 
     | 
    
         
            +
            - Established nested asset test cases
         
     | 
| 
      
 21 
     | 
    
         
            +
            - Created metadata-only node fixtures
         
     | 
| 
      
 22 
     | 
    
         
            +
             
     | 
| 
      
 23 
     | 
    
         
            +
            #### Phase 3: User Story 1 - Read Asset Data (T011-T031)
         
     | 
| 
      
 24 
     | 
    
         
            +
            **Goal**: Enable reading assets from the new simplified structure
         
     | 
| 
      
 25 
     | 
    
         
            +
             
     | 
| 
      
 26 
     | 
    
         
            +
            **Tests Written** (19 tests):
         
     | 
| 
      
 27 
     | 
    
         
            +
            - Collection#metadata_files unit tests
         
     | 
| 
      
 28 
     | 
    
         
            +
            - Collection#each with new structure tests
         
     | 
| 
      
 29 
     | 
    
         
            +
            - Node initialization with metadata_file tests
         
     | 
| 
      
 30 
     | 
    
         
            +
            - Node#id derivation from filename tests
         
     | 
| 
      
 31 
     | 
    
         
            +
            - Node#asset_dir returning node directory tests
         
     | 
| 
      
 32 
     | 
    
         
            +
            - Asset path resolution without /assets/ prefix tests
         
     | 
| 
      
 33 
     | 
    
         
            +
            - Integration tests for full workflow
         
     | 
| 
      
 34 
     | 
    
         
            +
            - Metadata-only node tests (FR-007)
         
     | 
| 
      
 35 
     | 
    
         
            +
             
     | 
| 
      
 36 
     | 
    
         
            +
            **Code Implemented**:
         
     | 
| 
      
 37 
     | 
    
         
            +
            - `Collection#metadata_files`: Scans for .yml, .yaml, .json, .toml files
         
     | 
| 
      
 38 
     | 
    
         
            +
            - `Collection#each`: Iterates metadata files instead of subdirectories
         
     | 
| 
      
 39 
     | 
    
         
            +
            - `Collection#get`: Finds nodes by metadata filename
         
     | 
| 
      
 40 
     | 
    
         
            +
            - `Node#initialize`: Accepts (collection, metadata_file) parameters
         
     | 
| 
      
 41 
     | 
    
         
            +
            - `Node#id`: Derives from metadata filename (without extension)
         
     | 
| 
      
 42 
     | 
    
         
            +
            - `Node#_load_base_attributes`: Loads from external metadata file
         
     | 
| 
      
 43 
     | 
    
         
            +
            - `Node#asset_dir`: Returns node directory (not assets/ subdirectory)
         
     | 
| 
      
 44 
     | 
    
         
            +
            - `Node#_ignored_files`: Treats all files in node dir as assets
         
     | 
| 
      
 45 
     | 
    
         
            +
            - `Asset` initialization: Handles new path structure
         
     | 
| 
      
 46 
     | 
    
         
            +
            - Backward compatibility maintained for old structure
         
     | 
| 
      
 47 
     | 
    
         
            +
             
     | 
| 
      
 48 
     | 
    
         
            +
            **Test Results**: ✅ 34/34 tests passing
         
     | 
| 
      
 49 
     | 
    
         
            +
             
     | 
| 
      
 50 
     | 
    
         
            +
            #### Phase 5: User Story 3 - Migrate Existing Assets (T042-T065)
         
     | 
| 
      
 51 
     | 
    
         
            +
            **Goal**: Provide migration tool to convert from old to new structure
         
     | 
| 
      
 52 
     | 
    
         
            +
             
     | 
| 
      
 53 
     | 
    
         
            +
            **Tests Written** (10 tests):
         
     | 
| 
      
 54 
     | 
    
         
            +
            - Migrator#initialize with options
         
     | 
| 
      
 55 
     | 
    
         
            +
            - Migrator#validate detecting old/new structures
         
     | 
| 
      
 56 
     | 
    
         
            +
            - Migrator#preview generating migration plans
         
     | 
| 
      
 57 
     | 
    
         
            +
            - Migrator#migrate_node for single node migration
         
     | 
| 
      
 58 
     | 
    
         
            +
            - Migrator#migrate_collection for collection migration
         
     | 
| 
      
 59 
     | 
    
         
            +
            - Migrator#migrate for full root migration
         
     | 
| 
      
 60 
     | 
    
         
            +
            - Migrator#backup creating backups
         
     | 
| 
      
 61 
     | 
    
         
            +
            - Migrator#rollback restoring from backup
         
     | 
| 
      
 62 
     | 
    
         
            +
             
     | 
| 
      
 63 
     | 
    
         
            +
            **Code Implemented**:
         
     | 
| 
      
 64 
     | 
    
         
            +
            - `Ro::Migrator` class with full migration capabilities
         
     | 
| 
      
 65 
     | 
    
         
            +
            - `bin/ro-migrate` command-line tool
         
     | 
| 
      
 66 
     | 
    
         
            +
            - Validation and structure detection
         
     | 
| 
      
 67 
     | 
    
         
            +
            - Migration preview (dry-run)
         
     | 
| 
      
 68 
     | 
    
         
            +
            - Automatic backup creation
         
     | 
| 
      
 69 
     | 
    
         
            +
            - Rollback support
         
     | 
| 
      
 70 
     | 
    
         
            +
            - Verbose logging
         
     | 
| 
      
 71 
     | 
    
         
            +
             
     | 
| 
      
 72 
     | 
    
         
            +
            **Features**:
         
     | 
| 
      
 73 
     | 
    
         
            +
            - Detects old vs new structure
         
     | 
| 
      
 74 
     | 
    
         
            +
            - Previews migration plan before execution
         
     | 
| 
      
 75 
     | 
    
         
            +
            - Creates timestamped backups
         
     | 
| 
      
 76 
     | 
    
         
            +
            - Moves metadata files to collection level
         
     | 
| 
      
 77 
     | 
    
         
            +
            - Moves assets from assets/ to node directory
         
     | 
| 
      
 78 
     | 
    
         
            +
            - Cleans up old structure
         
     | 
| 
      
 79 
     | 
    
         
            +
            - Supports dry-run mode
         
     | 
| 
      
 80 
     | 
    
         
            +
            - Force mode for mixed structures
         
     | 
| 
      
 81 
     | 
    
         
            +
            - Rollback from backup
         
     | 
| 
      
 82 
     | 
    
         
            +
             
     | 
| 
      
 83 
     | 
    
         
            +
            **Test Results**: ✅ 10/10 tests passing
         
     | 
| 
      
 84 
     | 
    
         
            +
             
     | 
| 
      
 85 
     | 
    
         
            +
            #### Documentation
         
     | 
| 
      
 86 
     | 
    
         
            +
            - Comprehensive MIGRATION.md guide
         
     | 
| 
      
 87 
     | 
    
         
            +
            - Migration tool usage examples
         
     | 
| 
      
 88 
     | 
    
         
            +
            - Troubleshooting guide
         
     | 
| 
      
 89 
     | 
    
         
            +
            - Breaking changes documented
         
     | 
| 
      
 90 
     | 
    
         
            +
            - Version compatibility matrix
         
     | 
| 
      
 91 
     | 
    
         
            +
             
     | 
| 
      
 92 
     | 
    
         
            +
            ### ⏭️ Skipped (Out of Scope)
         
     | 
| 
      
 93 
     | 
    
         
            +
             
     | 
| 
      
 94 
     | 
    
         
            +
            #### Phase 4: User Story 2 - Write Asset Data (T032-T041)
         
     | 
| 
      
 95 
     | 
    
         
            +
            **Reason**: Ro gem is primarily read-only. Write operations are not currently part of the core functionality. Migration tool handles structural changes, but runtime write operations were deemed out of scope for this feature.
         
     | 
| 
      
 96 
     | 
    
         
            +
             
     | 
| 
      
 97 
     | 
    
         
            +
            ### 📊 Final Statistics
         
     | 
| 
      
 98 
     | 
    
         
            +
             
     | 
| 
      
 99 
     | 
    
         
            +
            **Total Tests**: 44 tests (all passing)
         
     | 
| 
      
 100 
     | 
    
         
            +
            - Collection: 6 tests
         
     | 
| 
      
 101 
     | 
    
         
            +
            - Node: 12 tests
         
     | 
| 
      
 102 
     | 
    
         
            +
            - Asset: 5 tests
         
     | 
| 
      
 103 
     | 
    
         
            +
            - Integration: 11 tests
         
     | 
| 
      
 104 
     | 
    
         
            +
            - Migrator: 10 tests
         
     | 
| 
      
 105 
     | 
    
         
            +
             
     | 
| 
      
 106 
     | 
    
         
            +
            **Files Created/Modified**:
         
     | 
| 
      
 107 
     | 
    
         
            +
            - Created: 7 test files
         
     | 
| 
      
 108 
     | 
    
         
            +
            - Created: 1 implementation file (migrator.rb)
         
     | 
| 
      
 109 
     | 
    
         
            +
            - Modified: 4 core files (collection.rb, node.rb, asset.rb, ro.rb)
         
     | 
| 
      
 110 
     | 
    
         
            +
            - Created: 1 CLI tool (bin/ro-migrate)
         
     | 
| 
      
 111 
     | 
    
         
            +
            - Created: 2 documentation files (MIGRATION.md, this summary)
         
     | 
| 
      
 112 
     | 
    
         
            +
            - Created: Test fixtures (old and new structures)
         
     | 
| 
      
 113 
     | 
    
         
            +
             
     | 
| 
      
 114 
     | 
    
         
            +
            **Lines of Code**:
         
     | 
| 
      
 115 
     | 
    
         
            +
            - Test code: ~800 lines
         
     | 
| 
      
 116 
     | 
    
         
            +
            - Implementation code: ~400 lines
         
     | 
| 
      
 117 
     | 
    
         
            +
            - Documentation: ~300 lines
         
     | 
| 
      
 118 
     | 
    
         
            +
             
     | 
| 
      
 119 
     | 
    
         
            +
            ## Key Features Delivered
         
     | 
| 
      
 120 
     | 
    
         
            +
             
     | 
| 
      
 121 
     | 
    
         
            +
            ### 1. **Simplified Structure** ✅
         
     | 
| 
      
 122 
     | 
    
         
            +
            From: `identifier/attributes.yml` + `identifier/assets/`
         
     | 
| 
      
 123 
     | 
    
         
            +
            To: `identifier.yml` + `identifier/`
         
     | 
| 
      
 124 
     | 
    
         
            +
             
     | 
| 
      
 125 
     | 
    
         
            +
            ### 2. **Backward Compatibility** ✅
         
     | 
| 
      
 126 
     | 
    
         
            +
            Old structure continues to work seamlessly
         
     | 
| 
      
 127 
     | 
    
         
            +
             
     | 
| 
      
 128 
     | 
    
         
            +
            ### 3. **Multiple Metadata Formats** ✅
         
     | 
| 
      
 129 
     | 
    
         
            +
            Supports .yml, .yaml, .json, .toml
         
     | 
| 
      
 130 
     | 
    
         
            +
             
     | 
| 
      
 131 
     | 
    
         
            +
            ### 4. **Metadata-Only Nodes** ✅
         
     | 
| 
      
 132 
     | 
    
         
            +
            Nodes without assets work correctly (FR-007)
         
     | 
| 
      
 133 
     | 
    
         
            +
             
     | 
| 
      
 134 
     | 
    
         
            +
            ### 5. **Migration Automation** ✅
         
     | 
| 
      
 135 
     | 
    
         
            +
            Fully automated migration with safety features
         
     | 
| 
      
 136 
     | 
    
         
            +
             
     | 
| 
      
 137 
     | 
    
         
            +
            ### 6. **Path Resolution** ✅
         
     | 
| 
      
 138 
     | 
    
         
            +
            Assets load correctly without /assets/ segment
         
     | 
| 
      
 139 
     | 
    
         
            +
             
     | 
| 
      
 140 
     | 
    
         
            +
            ## Technical Highlights
         
     | 
| 
      
 141 
     | 
    
         
            +
             
     | 
| 
      
 142 
     | 
    
         
            +
            ### Clean Implementation
         
     | 
| 
      
 143 
     | 
    
         
            +
            - TDD approach: tests written first, all failing, then implementation
         
     | 
| 
      
 144 
     | 
    
         
            +
            - Minimal code changes to existing classes
         
     | 
| 
      
 145 
     | 
    
         
            +
            - Strong separation of concerns
         
     | 
| 
      
 146 
     | 
    
         
            +
            - Comprehensive error handling
         
     | 
| 
      
 147 
     | 
    
         
            +
             
     | 
| 
      
 148 
     | 
    
         
            +
            ### Safety Features
         
     | 
| 
      
 149 
     | 
    
         
            +
            - Automatic backups before migration
         
     | 
| 
      
 150 
     | 
    
         
            +
            - Dry-run mode for previewing changes
         
     | 
| 
      
 151 
     | 
    
         
            +
            - Validation to detect structure conflicts
         
     | 
| 
      
 152 
     | 
    
         
            +
            - Rollback capability
         
     | 
| 
      
 153 
     | 
    
         
            +
            - Extensive test coverage
         
     | 
| 
      
 154 
     | 
    
         
            +
             
     | 
| 
      
 155 
     | 
    
         
            +
            ### Developer Experience
         
     | 
| 
      
 156 
     | 
    
         
            +
            - Clear migration path documented
         
     | 
| 
      
 157 
     | 
    
         
            +
            - Command-line tool with helpful options
         
     | 
| 
      
 158 
     | 
    
         
            +
            - Detailed error messages
         
     | 
| 
      
 159 
     | 
    
         
            +
            - Verbose logging option
         
     | 
| 
      
 160 
     | 
    
         
            +
             
     | 
| 
      
 161 
     | 
    
         
            +
            ## Migration Path
         
     | 
| 
      
 162 
     | 
    
         
            +
             
     | 
| 
      
 163 
     | 
    
         
            +
            1. **Upgrade to Ro v5.0** (backward compatible)
         
     | 
| 
      
 164 
     | 
    
         
            +
            2. **Run migration tool**: `./bin/ro-migrate /path/to/root`
         
     | 
| 
      
 165 
     | 
    
         
            +
            3. **Verify** data loads correctly
         
     | 
| 
      
 166 
     | 
    
         
            +
            4. **Clean up** old backups after confidence
         
     | 
| 
      
 167 
     | 
    
         
            +
             
     | 
| 
      
 168 
     | 
    
         
            +
            ## Performance Impact
         
     | 
| 
      
 169 
     | 
    
         
            +
             
     | 
| 
      
 170 
     | 
    
         
            +
            - **Read Performance**: Improved (one less directory traversal)
         
     | 
| 
      
 171 
     | 
    
         
            +
            - **Discovery**: Same (scans collection directory)
         
     | 
| 
      
 172 
     | 
    
         
            +
            - **Path Resolution**: Improved (simpler path calculations)
         
     | 
| 
      
 173 
     | 
    
         
            +
            - **Migration**: One-time operation, completes quickly
         
     | 
| 
      
 174 
     | 
    
         
            +
             
     | 
| 
      
 175 
     | 
    
         
            +
            ## Breaking Changes
         
     | 
| 
      
 176 
     | 
    
         
            +
             
     | 
| 
      
 177 
     | 
    
         
            +
            ### None for Read Operations
         
     | 
| 
      
 178 
     | 
    
         
            +
            All existing code that reads assets continues to work. The changes are additive and maintain backward compatibility.
         
     | 
| 
      
 179 
     | 
    
         
            +
             
     | 
| 
      
 180 
     | 
    
         
            +
            ### For Migrations
         
     | 
| 
      
 181 
     | 
    
         
            +
            - Manual migrations from old→new structure need to follow new pattern
         
     | 
| 
      
 182 
     | 
    
         
            +
            - Old structure will be deprecated in future major version
         
     | 
| 
      
 183 
     | 
    
         
            +
             
     | 
| 
      
 184 
     | 
    
         
            +
            ## Future Work
         
     | 
| 
      
 185 
     | 
    
         
            +
             
     | 
| 
      
 186 
     | 
    
         
            +
            ### Recommended for v6.0
         
     | 
| 
      
 187 
     | 
    
         
            +
            - Remove old structure support
         
     | 
| 
      
 188 
     | 
    
         
            +
            - Deprecate old initialization patterns
         
     | 
| 
      
 189 
     | 
    
         
            +
            - Performance optimizations for large collections
         
     | 
| 
      
 190 
     | 
    
         
            +
             
     | 
| 
      
 191 
     | 
    
         
            +
            ### Optional Enhancements
         
     | 
| 
      
 192 
     | 
    
         
            +
            - Write operations (if needed)
         
     | 
| 
      
 193 
     | 
    
         
            +
            - Streaming migration for very large datasets
         
     | 
| 
      
 194 
     | 
    
         
            +
            - Migration progress reporting
         
     | 
| 
      
 195 
     | 
    
         
            +
            - Parallel migration for faster processing
         
     | 
| 
      
 196 
     | 
    
         
            +
             
     | 
| 
      
 197 
     | 
    
         
            +
            ## Conclusion
         
     | 
| 
      
 198 
     | 
    
         
            +
             
     | 
| 
      
 199 
     | 
    
         
            +
            Successfully implemented the asset structure simplification with:
         
     | 
| 
      
 200 
     | 
    
         
            +
            - ✅ Full test coverage (44/44 tests passing)
         
     | 
| 
      
 201 
     | 
    
         
            +
            - ✅ Backward compatibility maintained
         
     | 
| 
      
 202 
     | 
    
         
            +
            - ✅ Production-ready migration tool
         
     | 
| 
      
 203 
     | 
    
         
            +
            - ✅ Comprehensive documentation
         
     | 
| 
      
 204 
     | 
    
         
            +
            - ✅ Zero data loss migration path
         
     | 
| 
      
 205 
     | 
    
         
            +
             
     | 
| 
      
 206 
     | 
    
         
            +
            The new structure is simpler, more intuitive, and easier to work with while maintaining full compatibility with existing code.
         
     | 
| 
      
 207 
     | 
    
         
            +
             
     | 
| 
      
 208 
     | 
    
         
            +
            ---
         
     | 
| 
      
 209 
     | 
    
         
            +
             
     | 
| 
      
 210 
     | 
    
         
            +
            **Implementation Date**: 2025-10-18
         
     | 
| 
      
 211 
     | 
    
         
            +
            **Version**: 5.0.0
         
     | 
| 
      
 212 
     | 
    
         
            +
            **Status**: ✅ Complete and Ready for Release
         
     | 
| 
         @@ -0,0 +1,36 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # Specification Quality Checklist: Simplify Asset Directory Structure
         
     | 
| 
      
 2 
     | 
    
         
            +
             
     | 
| 
      
 3 
     | 
    
         
            +
            **Purpose**: Validate specification completeness and quality before proceeding to planning
         
     | 
| 
      
 4 
     | 
    
         
            +
            **Created**: 2025-10-17
         
     | 
| 
      
 5 
     | 
    
         
            +
            **Feature**: [spec.md](../spec.md)
         
     | 
| 
      
 6 
     | 
    
         
            +
             
     | 
| 
      
 7 
     | 
    
         
            +
            ## Content Quality
         
     | 
| 
      
 8 
     | 
    
         
            +
             
     | 
| 
      
 9 
     | 
    
         
            +
            - [X] No implementation details (languages, frameworks, APIs)
         
     | 
| 
      
 10 
     | 
    
         
            +
            - [X] Focused on user value and business needs
         
     | 
| 
      
 11 
     | 
    
         
            +
            - [X] Written for non-technical stakeholders
         
     | 
| 
      
 12 
     | 
    
         
            +
            - [X] All mandatory sections completed
         
     | 
| 
      
 13 
     | 
    
         
            +
             
     | 
| 
      
 14 
     | 
    
         
            +
            ## Requirement Completeness
         
     | 
| 
      
 15 
     | 
    
         
            +
             
     | 
| 
      
 16 
     | 
    
         
            +
            - [X] No [NEEDS CLARIFICATION] markers remain
         
     | 
| 
      
 17 
     | 
    
         
            +
            - [X] Requirements are testable and unambiguous
         
     | 
| 
      
 18 
     | 
    
         
            +
            - [X] Success criteria are measurable
         
     | 
| 
      
 19 
     | 
    
         
            +
            - [X] Success criteria are technology-agnostic (no implementation details)
         
     | 
| 
      
 20 
     | 
    
         
            +
            - [X] All acceptance scenarios are defined
         
     | 
| 
      
 21 
     | 
    
         
            +
            - [X] Edge cases are identified
         
     | 
| 
      
 22 
     | 
    
         
            +
            - [X] Scope is clearly bounded
         
     | 
| 
      
 23 
     | 
    
         
            +
            - [X] Dependencies and assumptions identified
         
     | 
| 
      
 24 
     | 
    
         
            +
             
     | 
| 
      
 25 
     | 
    
         
            +
            ## Feature Readiness
         
     | 
| 
      
 26 
     | 
    
         
            +
             
     | 
| 
      
 27 
     | 
    
         
            +
            - [X] All functional requirements have clear acceptance criteria
         
     | 
| 
      
 28 
     | 
    
         
            +
            - [X] User scenarios cover primary flows
         
     | 
| 
      
 29 
     | 
    
         
            +
            - [X] Feature meets measurable outcomes defined in Success Criteria
         
     | 
| 
      
 30 
     | 
    
         
            +
            - [X] No implementation details leak into specification
         
     | 
| 
      
 31 
     | 
    
         
            +
             
     | 
| 
      
 32 
     | 
    
         
            +
            ## Notes
         
     | 
| 
      
 33 
     | 
    
         
            +
             
     | 
| 
      
 34 
     | 
    
         
            +
            - All checklist items passed validation
         
     | 
| 
      
 35 
     | 
    
         
            +
            - Clarifications resolved: Conflict resolution strategy (prefer old structure until migrated) and backward compatibility approach (breaking change with major version bump)
         
     | 
| 
      
 36 
     | 
    
         
            +
            - Spec is ready for `/speckit.plan`
         
     |