question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

dat automatically finds <dat.json>

See original GitHub issue

If I type dat . or dat clone dat.json or dat clone . in a directory that has a dat.json file, it should use the url key in the file. This is nice for github repos so I just add the hash once in the dat.json file and forget about it.

Issue Analytics

  • State:open
  • Created 7 years ago
  • Comments:11 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
TimothyStilescommented, Aug 9, 2017

It looks like the default behavior for dat clone . when there’s already a .dat folder is to listen for updates. I’m just going to leave that be.

1reaction
TimothyStilescommented, Aug 9, 2017

@joehand I’ve put together a pull request that checks for and parses dat clone . and dat clone path/to/dat.json that I haven’t submitted yet.

dat clone . and dat clone dat.json both clone the content of the dat repo directly into the current working directory without a fourth dir argument.

dat clone path/to/dat.json without a dir argument makes a new directory named after the key link which contains the dat repo.

dat clone path/to/dat.json dir works as expected.

I’ve only tried this with empty directories with a single dat.json file in it. It looks like I should also write something that throws an error if there’s already a .dat folder within the target directory. Should I make that as a second pull request or roll that into the one I’m about to make?

Also, I can’t key pass clone a null value such as dat clone. I think it has something to do with src/parse-args.js. I tried writing a test using the clone - default ops as a template but I’ve been running into trouble.

Read more comments on GitHub >

github_iconTop Results From Across the Web

is there a way to read .dat files as in the storage format for ...
I'll try to find time for a write-up of the exact format. ... blckdat-stream only "parses" the dat files in that it chunks...
Read more >
dat-json-replicator - npm Package Health Analysis - Snyk
Replicate a dat instance to another one in a dumb way using the JSON changes feed and a bunch of attachment GETs For...
Read more >
dat-json - GitHub
Write a single key and value or an object, data , to the dat.json file. Use file option above to also update the...
Read more >
Dat Questions - Dat Docs
Dat does not import or copy your data into specialized databases. You can easily move your data around, and Dat keeps it intact...
Read more >
How To Open .DAT File - Software Testing Help
You will also learn to open Winmail.dat on iPhone, iPad & Mac OS. ... However, in some rare cases, you can find them...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found