Docs

Refresh and your files

Bitling keeps track of which files it wrote for you and which are yours. Your code is never silently overwritten.

Two kinds of files

Who owns each file in a project
Owner Files What Bitling may do
Bitling README.md, problem.html, .practice/problem.json Rewrite them with fresh content when you refresh.
You Your solution, your tests, and the build files (for example build.gradle.kts) Create them once, then leave them alone, even if you never edited them.

The list lives in .practice/manifest.json. It records the template and generator version, and each file's owner and a fingerprint (a SHA-256 hash) of what Bitling wrote. Bitling uses it to recognize a project it already created and to tell its files apart from yours.

Opening a problem you already have

When you open the popup on a problem that already has a project, Bitling notices and offers to open it instead of creating it again. Creating never writes over an existing project: you'll see Already in your workspace, and nothing is changed.

If the folder where the project would go holds a different problem, Bitling says That folder holds another problem and leaves it alone.

What Refresh does

Problem pages change, and Bitling's readers get better. Refresh rebuilds a project's Bitling files from the problem as it is now:

  • Bitling's files are replaced with fresh content, or left as they are when nothing changed.
  • Your files are left exactly as they are. The summary names them, so you can see they weren't touched.
  • If a newer template adds a file of yours that doesn't exist yet, it's created. Existing files are never replaced.
  • Files of yours that you deleted stay deleted. The summary lists them as not restored.
  • Ownership recorded when the project was created wins, so a later template can't turn one of your files into one Bitling rewrites.
  • If the folder turns out to belong to another problem, nothing is refreshed.

Refresh is in the popup when you use the extension on its own: open it on the problem and click Refresh. With the desktop app, the popup doesn't offer Refresh yet.

Refresh never merges anything into your code. If you'd like a clean start on a problem, move its project folder out of your project folder entirely, then create the project again. Renaming it in place isn't enough: Bitling recognizes the problem by what's inside the folder, not by its name.