Workflow to upstream project symbols

Hey guys,

I cannot seem to get a sane workflow going to upstream my symbols.

How can I save my project library files to the right spot of the global library so that I can push it to github?
Currently the only way I found is copying the data into the files via text editor, which is prone to error and generally not professional.

Thanks for the help :slight_smile:

Make a personal github fork of the lib. Clone that fork locally. Add the official repo as a second remote repo. Point kicad to the local clone via environment variables. Make the changes directly with kicad.

I personally have 4 clones of the libs locally.
One points to the last release tag, one points to the backport release, one is setup to be read only on the official repo for reviewing pull requests, one points to my personal fork (It also has the official repo as read only remote set for syncing my repo with the official repo).

I use the environment variables to switch between the local clones depending on what i need to do.


For every contribution first fetch in the current state of the official repo and create a new branch at the HEAD of the official repo master.


The commands you will need to setup your contribution clone:

git clone git@github.com:herostrat/kicad-symbols.git
cd kicad-symbols
git remote add upstream git@github.com:KiCad/kicad-symbols.git
git remote set-url upstream --push "no push"

From then on you can use the following to add your changes:

git fetch upstream
git checkout upstream/master
git checkout -b new_branchname
git push --set-upstream origin new_branchname

Make your changes followed by

git add list_of_files
git commit
git push

If changes are requested by the maintainers:
git checkout branchname
change stuff

git add list_of_files
git commit
git push

for reviewing changes (using the same clone as above)

git fetch upstream pull/PRnr/head
git checkout FETCH_HEAD

PRnr is the pull request number

2 Likes

Hey thanks for the help (and the awesome work you do, it is really more than impressive…)

I meant more in the KiCad workflow sense, not for git.


Lets say I have some footprints in my project specific folder for symbols (e.g. myproject.dcm and myproject.lib)

I don’t find a way to save those footprints in another library.

Intuitive would be:
Open the footprint from project library -> save as -> save to global library
But this does not exist.
I tried doing it using the export/import, which of course is also not correct.

I think I am using the tool wrong and don’t understand the intended workflow for this, because I am pretty sure there is an easy way!

For symbols (kicad version 5):
right click on the symbol name in the left side bar -> copy
right click on the target library -> paste

For footprints:
open the footprint using the footprint browser
save footprint and in the dialog that opens select the target lib

The footprint stuff already works the same way as the symbol editor in current nightlies. So kicad 5.1 will have both editors set up that way.

Oh man…now I feel stupid.

Thanks a lot :slight_smile:

I think this one also help to move part around very easy…
https://www.compuphase.com/electronics/kicadlibrarian_en.htm

I’ve looked at that web page recently, and the screen shots seem to indicate that is uses the legacy footprint library format. In your experience, does kicad librarian support the .pretty format and/or the new V5 footprint features?

I’m using it, and it work fine with .kicad_mod file which are in .pretty folders…
3D may not work correctly, but footprint is good, and it have automatically generate dimension drawing between pins - which very very handy. Below is a picture of example, and the addition dimension are in the “cyan” colors.

image

Note: I use to add addition hidden info like datasheet where the footprint base from, date, and name person last modified too…

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.