Tinacms: On Windows - unable to save edits

Created on 27 Oct 2019  Â·  2Comments  Â·  Source: tinacms/tinacms

Description

Attempting to edit a page results in failure when tinacms is deployed on Windows.

Steps to reproduce

  1. gatsby new my-tinacms-starter https://github.com/tinacms/gatsby-starter-tinacms

  2. cd gatsby-starter-tinacms

  3. gatsby develop

  4. Select a page

  5. Edit HTML

Expected result

What should happen?

HTML successfully edited, and see a new git commit.

Actual result

error: pathspec 'C:\dev\toyapps\my-tina-starter\C:\dev\toyapps\my-tina-starter\content\blog\hello-world\index.md' did not match any file(s) known to git

Environment

  • Windows 10

  • node v12.13.0

Notes

  1. The directory name was repeated twice

    'C:dev\toyapps\my-tina-starter\C:dev\toyapps\my-tina-starter\content\blog\hello-world\index.md'

  2. The fileRelativePath does not start with /content on Windows

{ "componentChunkName": "component---src-templates-blog-post-js", "path": "/hello-world/", "webpackCompilationHash": "", "result": { "data": { "site": { "siteMetadata": { "title": "Gatsby Starter Blog", "author": "Kyle Mathews" } }, "markdownRemark": { "id": "8c658351-c0c8-5559-83e7-64fb0d699edb", "excerpt": "This is my first post on my new fake blog! How exciting! I’m sure I’ll write a lot more interesting things in the future. Oh, and here’s a great quote from this…", "html": "<p>This is my first post ...</p>", "fileRelativePath": "C:/dev/toyapps/my-tina-starter/content/blog/hello-world/index.md", "rawFrontmatter": "{\"title\":\"Hello World\",\"date\":\"2015-05-01T22:12:03.284Z\",\"description\":\"Hello World\"}", "rawMarkdownBody": "\r\nThis is my first post on...\r\n", "frontmatter": { "title": "Hello World", "date": "May 01, 2015", "description": "Hello World" } } }, "pageContext": { "isCreatedByStatefulCreatePages": false, "slug": "/hello-world/", "previous": null, "next": { "fields": { "slug": "/my-second-post/" }, "frontmatter": { "title": "My Second Post!" } } } } }

bug windows

Most helpful comment

Thanks I can confirm canary works on Windows

All 2 comments

A canary release has been published that should have this fix. Once it's confirmed that the canary works, I will cherry-pick this to next and then latest.

Thanks I can confirm canary works on Windows

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lyleunderwood picture lyleunderwood  Â·  4Comments

canrozanes picture canrozanes  Â·  3Comments

kendallstrautman picture kendallstrautman  Â·  3Comments

scottgallant picture scottgallant  Â·  4Comments

sky172839465 picture sky172839465  Â·  4Comments