i know the way android stores application config and so on makes it almost imposible to keep a real functioning dotfiles. but what is the closest you can get? is there a way to at least get a declarative list of apps to install or something? maybe some f-droid config at least or something?
deleted by creator
The closest you could actually get is to set up your own MDM system that provisioned your device from a configuration upstream
do you know if there is a good open source MDM? i feel like it wouldn’t work very well without root, though… :(
Funny enough you don’t need to root a phone for MDM generally because otherwise “bring your phone to work” systems would never work. It’s a very classic case of “rules for thee but not for me” because it gets in the way of corporate profit.
That being said the only open source MDM I’m aware of with real capability and stability is https://fleetdm.com/. I would stay far away from anything vibe coded or even just younger than a year
EDIT: after looking at it, it appears Google locks MDM capability though “Android enterprise” or whatever the fuck that is and you need to tie it to a domain name so ymmv
I remember a local infosec website selling people on a MDM for the entire family, advertised as being able to do parental control and block scam apps
dotfiles are just text files with a . as the first character there isn’t anything inherently magic about them other than many file browsers hiding them by default.
What functionality are you looking for with them? Configuration and secure tokens?
when i said dotfiles i meant a dotfiles repo, i think this is hugely obvious. not sure what part you don’t understand. and also, no, dotfiles are not necessarily text files.
so i’m essentially asking if it’s posible to keep track of my android configs in some similar way.
Use the export/backup functionality of the app and sync that.
It might be hugely obvious to you, but in a generic sense “dotfiles” are just files preceded by a dot… I wouldn’t have guessed you meant a git repo but after searching it seems it’s a bit of a unixporn trend? Never heard of it until now.
I’ve personally only ever heard the term “dotfiles” used in the context of a collection of customized config files. To be honest I can’t remember ever hearing a term used for
.*files/folders in general, outside of maybe “hidden directories”? Granted, it could also just be that we’re existing in different bubbles.i’ve never heard of anyone using dotfiles in any other way, even thought yeah a hidden file/directory is a dotfile, people discuss much more in the way i mention it because it implies a lot more stuff. i agree with the other comment that when you refer to the individual file people call them hidden files, nautilus and other file managers do this. i guess my reply wasn’t the best but i thought they were being smug about it.
Hugely obvious is very relative dear, good luck!
There’s Termux on Android, which you could have ‘dotfiles’ for. There’s individual apps which sometimes have automated backups. And there’s applications that don’t have backups, or system-level settings. Being clear in your question goes a longer way than being sassy :3
As to your actual question, that’s still rather vague, because the easy answer is “backing up your entire phone”, and the longer answer is “what are you backing up with regards to Android?” Android’s system settings, within the ‘Settings’ app, is broken out even over the ADB CLI over multiple different commands, so there’s no straightforward clear question or answer here.
Your best bet is just picking apps to use that have an ‘export’ feature, and maybe using Syncthing to sync a folder with a server/computer and export the settings into that folder. I basically do that but with Nextcloud, exporting directly to a ‘Backups’ folder in my Nextcloud, sometimes with nested subfolders for grouping things. As long as Nextcloud is installed and signed in, it’s usually trivial to import them then into those apps.
But again, that’s app choice, and per-app. I can export my settings for Material File Manager, but I can’t really export them for Tempus, nor, irritatingly, HeliBoard.
If you’re rooted you might be able to set up some kind of per-app backup of their individual /data directories with something like Titanium.
i guess i was rather vague because i know that it’s essentially a mess and how much you can save depends largely on how the app decides to save its config and so on, on the manufacturer and hos the system settings are saved and so on. so i guess that my question was more like, has anyone managed to do android dotfiles in a meaningful way beyond termux? i agree i was sassy but i thought the previous comment was being smug. i have never heard of anyone mention dotfiles outside of this use, so i guess that’s a bad on me.
i think the stuff i’d like to backup the most would be some sort of declarative list of installed apps, if possible some system wide settings althought with how messy phones are with settings i doubt it, and maybe a couple of special per app settings. do you know if this is easier of Oses like graphene o lineage?
Installed apps is hard cause they could be from the Play store or from F-Droid or Obtanium or raw APK installs.
Of those, Obtanium let’s you export things and import. Some F-Droid clients will do that too, but the stock one will only export – I don’t see a mechanism for import. Play store is usually automatic with their migration feature.
So it sounds less like you want “dotfiles” and more you want a declarative Nix config for Android. Wildly different meanings. And neither really something Android does at all and isn’t built around. It’d be like trying to turn an average Ubuntu install with some third-party DEBs sans sources into Nix, except half your apps store their info in Root somehow and you don’t have root access.
This is why stuff like Titanium Backup exists. Fundamentally, this is an X-Y problem presented – the assumption your stated method (Nixification and system settings) is the means to achieving an ends (backup you can transfer around, or to wipe of the same device).
Unless Nixification itself is the sole goal for the sake of “project”, in which case, why be asking instead of making? X3 You might find something more like that in a Linux distro for a phone like Nura/postmarket or building one. But Android’s architecture is too weird for cleanly doing that.







