Skip to content

doc: Multi-Profile system documentation#20751

Open
criticalAY wants to merge 1 commit intoankidroid:mainfrom
criticalAY:mp/doc
Open

doc: Multi-Profile system documentation#20751
criticalAY wants to merge 1 commit intoankidroid:mainfrom
criticalAY:mp/doc

Conversation

@criticalAY
Copy link
Copy Markdown
Contributor

Purpose / Description

Document how mulit-profile works and how the folder structure looks like

Fixes

NA

Approach

NA

How Has This Been Tested?

NA

Learning (optional, can help others)

Always document first so that we don't mess up later

Checklist

Please, go through these checks before submitting the PR.

  • You have a descriptive commit message with a short title (first line, max 50 chars).
  • You have commented your code, particularly in hard-to-understand areas
  • You have performed a self-review of your own code
  • UI changes: include screenshots of all affected screens (in particular showing any new or changed strings)
  • UI Changes: You have tested your change using the Google Accessibility Scanner

Comment thread docs/multiprofile/README.md Outdated
│ └── ...
├── app_webview/ # Used by the "Default" (legacy) profile
├── databases/ # Used by the "Default" (legacy) profile
├── files/ # Used by the "Default" (legacy) profile
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note that this is different from files below

Comment thread docs/multiprofile/README.md Outdated

### Internal storage(located at /data/data/com.ichi2.anki/):
/data/data/com.ichi2.anki/
├── Alice/ # Created by setDataDirectorySuffix("Alice")
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we not using profileIds here?

What if someone makes a profile named 'shared_prefs'?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes but I thought it's simpler to explain using name instead as we have done in original issue

Comment thread docs/multiprofile/README.md Outdated
Comment on lines +29 to +41
/storage/emulated/0/Android/data/com.ichi2.anki/files/
├── AnkiDroid/ # Default Profile Root
│ ├── collection.anki2
│ ├── collection.media/
│ └── backup/
├── Alice/ # Default Profile Root
│ ├── AnkiDroid
│ ├── collection.anki2
│ ├── collection.media/
│ └── backup/
├── Bob/
│ ├── AnkiDroid
│ ...
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How does AnkiDroid Directory work with this?

Comment thread docs/multiprofile/README.md Outdated
Comment on lines +48 to +49
- The metadata is serialized into a JSON string and saved into the global profiles_prefs.xml file.
- The profile is "registered" but "dormant." No folders exist on the disk yet.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • It would be useful to have a sample structure + definition of the global registry
  • Maybe a glossary to disambiguate the names of the global registry and the 'profile-specific' shared preferences

@criticalAY criticalAY added Needs Author Reply Waiting for a reply from the original author and removed Needs Review labels Apr 18, 2026
@criticalAY criticalAY added Needs Review and removed Needs Author Reply Waiting for a reply from the original author labels Apr 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants