-
-
Notifications
You must be signed in to change notification settings - Fork 39.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Split Firmware off from Keymaps #1120
Comments
This might also help make #1038 easier to deal with. |
Having them in a branch of qmk_firmware may work, but this is interesting. What would you propose in terms of the tapping? Do you have a script in mind for this, or would it just be a git submodule thing? Any sort of fancy thing like this would make everything more complicated for new-comers, though. Having everything in one (albeit large) repo does make it a lot easier to get started. |
I'm not sure what would work the best, my instinct leads me to want to write something in python to manage it all, again, similar to homebrew. But maybe just a submodule would be easiest.
I think it may be a safe assumption that if someone is looking for a new keymap or to make their own, they probably can handle an extra repo. At minimum though, keep board configs and a basic qwerty layout for each board in the main firmware repo, then put community keymaps in their own. ...Or, you could leave the main supported qmk boards in the firmware repo, and move 3rd party to external, etc. There's a few ways for something like this to go down, what's best though, idk. |
My suggestion would be to include the main firmware as a submodule to the keymap repo. |
Personally I prefer it the way it is now, at least for maintainers. When everything is in the same repository, it's easy to search where features are used, and even to make global refactoring. But if things were to be changed we should at least at the minimum still support building everything with a single make command to make sure everything compiles, and also make sure that we still build everything as a part of the continuous integration server. The biggest problem with submodules is that in many cases, you have to make two pull requests. First for the actual QMK feature or fix, and then for the keymap that relies on it. You would also actually have to wait for the QMK to be merged so that you can point the kemap submodule to the right path and version. And if there are several people doing all this is parallel we will have many complicated merge problems. At least that's my experience with submodules, but there might be a better way to use them. As for the changelog, that could indeed be a problem. The best way currently to get an idea what has been changed is probably to check list of merged pull request rather than the actual commit log. It's also possible to filter out all keymaps when you view the GIT log, at least by using the GIT command line. The optimal solution would be if someone had time to maintain an easily readable list of changes on the wiki. That would not only include new features and bug fixes, but also code breaking changes that would require changes to existing keymaps, including instructions how to fix that. |
What if all the core firmware development was on a separate branch that has "releases." The releases would get merged into master, which is where all the keymap stuff would be. So if someone wants to look at the firmware changes, they can just search the firmware branch in the commit log. I'm kinda new to large open source projects, so just let me know your thoughts. |
Thanks for bringing this up, and this is a good discussion, but we're going to stick with encouraging users to fork the entire repo for now! |
Keymaps kept together with firmware really is a mess. I'm watching this repo and I'm really tired of "Added yet another keymap" commits. If you insist on having some keymaps together with firmware I think there should be one "default" keymap per keyboard type just to be able to quickly try it out and the rest should go into separate repo. |
I wouldn't mind having a few keymaps supported by the keyboard maintainer, then having the rest in some sort of contributor keymaps repo. I'd like for the make system to be able to support building keymaps/keyboards outside of the qmk_firmware folder - I think that's the only thing that would need to happen to jump-start this. |
There are some valid hesitations to using submodules, so I'd like to talk through some options with this. If we assume some will download/clone both repos, they could get a folder structure like this:
Where |
I used to be on the "lets have one giant repo with a ton of keymaps" side, because:
But it also has downsides:
Having worked with
We lose a bit on the discoverability side (but a WiKi can go a long way there), and one will need to clone two repos, but... that's not such a big deal, I found, and can easily be scripted and documented. I would not, however, force Thus, as far as the build system goes, I'd suggest the following that |
@algernon really hits the nail on the head. For a long time I kept my keymaps on a separate branch, merging in upstream master. This has always felt awkward and hacky to me. The discoverability of other keymaps has made it easier to learn from other setups, but there's also a ton of noise from them. Today I split my keymaps off to their own repo so they can be maintained easier. I keep qmk master up to date and I compile out of my keymaps repo. This way it treats QMK more like a dependency of the keymap. I'm definitely in favor of this workflow and with some core support this could be a viable process. |
With the addition of #1609, it might be worth considering organising the contributor keymap repo with layout keymaps, rather than keyboard ones. There's also the argument that there shouldn't be any keymaps in the layout folders in the core repo, but I could see wanting some examples (maybe even |
keeping a default map for each board in core would make sense. |
Each keyboard would have a I wrote a little bit about using layouts for this:
|
#1609 has been merged, so now it's just a matter of abstracting and moving the user keymaps into the It may be worth considering something to restrict layout keymaps to certain keyboards with the |
Also, (once it's fully fixed), the version should be incremented for important changes only. That would mean that docs, keyboards, layouts and user spaces wouldn't increment the version. Anything else would, and that would make it much easier to tell if serious commits have occurred. Additionally, you can view the history of a folder, such as |
I support the way to make the |
I've been thinking about this a lot, actually. One of the issues that has cropped up now, is that there is the "userspace" feature. This makes this entire topic much more problematic. It means that we'd need two submodules (one for keymaps, and one for userspace), or we'd need to reorganize the layouts and userspace into a single folder: Which isn't a bad idea. The only downside, is that we'd really need to enable layout support for EVERY keyboard, and have a layout name for every layout. It would create a lot of work. In the meanwhile, I've been trying to add |
I've been running an experiment over the last year keeping my keymaps in their own repo using a custom cli and treating qmk_firmware as a lib only. It's been awesome. The implementation is a bit hacky due to having to copy keymaps in the lib, instead of including the lib in the keymaps, but it's been a ton easier for me to maintain a growing list of boards. Prototyping this has made me want qmk to be setup as separate repos:
Splitting them up reduces noise in the main repo. It's a lot easier to focus on features, bugs, and support related to the firmware itself. Keyboards and layouts are still discoverable, and the CLI can use a real programming language, potentially making it much easier to maintain. |
I was thinking about this recently, and put this together as a template we can (eventually, on the qmk org) let people fork and customise: https://github.com/jackhumbert/qmk_firmware_embeded It requires minimal changes to the QMK core (something we should be able to easily merge), and is mostly just cleaning up the paths (see the |
I'm also doing the separate repo + QMK as submodule + custom CLI thing. It's far more usable and useful than trying to deal with having my layout live in a subdir of QMK. I only have one QMK keyboard, so it's not even like that use case is limited to people with multiple layouts. |
This issue has been automatically marked as stale because it has not had activity in the last 90 days. It will be closed in the next 30 days unless it is tagged properly or other activity occurs. |
Hey, I'd really want to have a way to use a separate repo for my keymaps, and that's something I partially achieved there, however I needed to supply #19679 to fix misbehaving Makefiles. Couldn't we just add a EDIT: typos |
* try to add mt3 colourway * Merge branch 'qmk:master' into mt3_tty * fix lint 1 * fix lint 2 * apply proper keyset name for MT3 /dev/tty * apply inset key colors for MT3 /dev/tty * apply inset key colors for MT3 Susuwatari Co-authored-by: alin m elena <[email protected]> Co-authored-by: alin m elena <[email protected]>
How do things stand nowadays? |
@keyboard-magpie |
This got missed. KB PRs would still go to the main repo Also, I think this can probably be closed, now |
I think the main qmk firmware and the keymaps should be put into their own repos and have a 'tap' setup sort of like Homebrew has? The current setup makes it extremely difficult to keep up with any changes to the base firmware since new keymaps and fixes to them pollute the commit log. Would also have the benefit that you could only 'tap' the keymaps for the keyboard you have, or could host on your own repo.
Just a thought I've had for a while now.
The text was updated successfully, but these errors were encountered: