Difference between revisions of "Charon"

From CUSF Wiki
Jump to navigation Jump to search
(Update Charon from latest on GitHub)
m
 
(11 intermediate revisions by the same user not shown)
Line 1: Line 1:
= Hades =
''This page is unfinished''


Hell itself (aka a minimal Windows vm). Designed for use with [https://github.com/smh-my-head/charon Charon]
Charon is an integration between [[Git]] and SolidWorks, designed by
[[User:HenryFranks|Henry Franks]] and [[User:EllieClifford|Ellie Clifford]]
eliminate the re-occuring problem of having >10 versions of a CAD assembly on
the Google Drive (with only one person understanding it). It is named after the
ferryman to Hell (for obvious reasons).


Documentation: [http://creativecommons.org/licenses/by-sa/4.0/ [[File:https://img.shields.io/badge/License-CC%20BY--SA%204.0-lightgrey.svg|CC BY-SA 4.0]]]
The GitHub repository can be found [https://github.com/smh-my-head/charon here].
You are welcome to contribute.


Code: [https://www.gnu.org/licenses/gpl-3.0.html [[File:https://img.shields.io/badge/License-GPL%20(%3E%3D%203)-lightgrey.svg|CC BY-SA 4.0]]]
It is assumed in this page that you understand [[Git and GitHub]], please read
that page first. Charon aims to keep the overall workflow as similar as
possible to using Git for code, but with a new merge and diff driver to enable
working with SolidWorks' binary file formats.


Tested on Windows 10 20H2 v2 with SolidWorks 2018 SP3
= Features and Usage =


== Installation ==
[[File:Charon hades example.png|thumb|800px|A graphical difference shown by Charon (running
on [[Hades]])]]


If you know any of the contributors personally and have licenses for all of the required proprietary software, drop one of us a message and we can pass on working image (9.9GB, all credit to @henryefranks).
== Enhanced diffs ==


Otherwise, have a look at [[docs/install.md|docs/install.md]] to set up the VM from scratch. If you are some sort of masochist and want to do it from scratch despite knowing the contributors, we can send you all the proprietary files necessary (20GB).
Without Charon, all <code>git diff</code> can tell you is that two files are
different. With charon enabled, <code>git diff</code> will open SolidWorks to
show you an interactive, graphical diff between the files, as shown in the screenshot.


== Tweaks ==
Note that due to technical limitations caused by Solidworks, Charon cannot
leave SolidWorks in this state, you will need to open the compare tool manually
(under ''Tools -> Compare'')


You may like to have a look through the other files in [[docs/|docs/]], which contain tweaks and features you may want to use. These are all implemented in the minimal image we can provide. Note that [[docs/ssh.md|docs/ssh.md]] is required for [https://github.com/smh-my-head/charon Charon]
== Usable mergetool ==


== A Note on SolidWorks Network Licences ==
''This output is not stable at the moment, it could change''


Using this without a SolidWorks Network License contravenes the SolidWorks licensing. However, this procedure ''does'' successfully convince SolidWorks that it’s not in a VM. This is justifiable because there are artificial locks against using “unsupported” hypervisors, so you couldn’t do it without tricking SolidWorks even with the correct license.
Charon makes merging branches actually possible (but it will never be that
easy...). A merge conflict will result in something like the following:


== License ==
<source>
Disconnect_Puller.SLDPRT conflicts. Choose one of the following options:
  local:  take the local  file (what you are merging into)
  remote: take the remote file (what you are merging)
  edit:  open the files in SolidWorks to edit manually
  abort:  abort the merge resolution
Enter your choice:
</source>


The files [[OVMF_CODE.fd|OVMF_CODE.fd]] and [[OVMF_VARS.qcow2|OVMF_VARS.qcow2]] are licensed according to [[EDK2_LICENSE|EDK2_LICENSE]].
Most of the options are fairly self explanatory, the interesting one is
<code>edit</code>. It will open the files in exactly the same way as
[[Hades#Enhanced diffs|the diff tool]], and you can view and/or edit them.
After you exit solidworks, you will be returned to the menu. (Your edits to the
files will be saved). You can then choose a file to take.


This file is licensed under a [http://creativecommons.org/licenses/by-sa/4.0/ Creative Commons Attribution-ShareAlike 4.0 International License]. See [[DOC_LICENSE|DOC_LICENSE]].
= Installation =


[http://creativecommons.org/licenses/by-sa/4.0/ [[File:https://licensebuttons.net/l/by-sa/4.0/88x31.png|CC BY-SA 4.0]]]
== Enabling Charon in a repository ==
 
To enable Charon in an existing repository, add it as a submodule and run the
setup script:
 
<source lang="bash">
git submodule add https://github.com/smh-my-head/charon
./charon/setup.sh
</source>
 
== Cloning a repository that uses Charon ==
 
When cloning a repository that uses Charon, you will also need to need to run
the setup script. Something like:
 
<source lang="bash">
git clone https://github.com/cuspaceflight/repository-that-uses-charon
cd repository-that-uses-charon
git submodule update --init
./charon/setup.sh
</source>
 
== Updating Charon ==
 
You may want to update Charon if improvements are made. To do this, update the
submodule and then run the setup script again (each user will need to run the
setup script):
 
<source lang="bash">
git submodule update --remote
./charon/setup.sh
</source>

Latest revision as of 21:19, 25 April 2024

This page is unfinished

Charon is an integration between Git and SolidWorks, designed by Henry Franks and Ellie Clifford eliminate the re-occuring problem of having >10 versions of a CAD assembly on the Google Drive (with only one person understanding it). It is named after the ferryman to Hell (for obvious reasons).

The GitHub repository can be found here. You are welcome to contribute.

It is assumed in this page that you understand Git and GitHub, please read that page first. Charon aims to keep the overall workflow as similar as possible to using Git for code, but with a new merge and diff driver to enable working with SolidWorks' binary file formats.

Features and Usage

A graphical difference shown by Charon (running on Hades)

Enhanced diffs

Without Charon, all git diff can tell you is that two files are different. With charon enabled, git diff will open SolidWorks to show you an interactive, graphical diff between the files, as shown in the screenshot.

Note that due to technical limitations caused by Solidworks, Charon cannot leave SolidWorks in this state, you will need to open the compare tool manually (under Tools -> Compare)

Usable mergetool

This output is not stable at the moment, it could change

Charon makes merging branches actually possible (but it will never be that easy...). A merge conflict will result in something like the following:

Disconnect_Puller.SLDPRT conflicts. Choose one of the following options:
  local:  take the local  file (what you are merging into)
  remote: take the remote file (what you are merging)
  edit:   open the files in SolidWorks to edit manually
  abort:  abort the merge resolution
Enter your choice:

Most of the options are fairly self explanatory, the interesting one is edit. It will open the files in exactly the same way as the diff tool, and you can view and/or edit them. After you exit solidworks, you will be returned to the menu. (Your edits to the files will be saved). You can then choose a file to take.

Installation

Enabling Charon in a repository

To enable Charon in an existing repository, add it as a submodule and run the setup script:

git submodule add https://github.com/smh-my-head/charon
./charon/setup.sh

Cloning a repository that uses Charon

When cloning a repository that uses Charon, you will also need to need to run the setup script. Something like:

git clone https://github.com/cuspaceflight/repository-that-uses-charon
cd repository-that-uses-charon
git submodule update --init
./charon/setup.sh

Updating Charon

You may want to update Charon if improvements are made. To do this, update the submodule and then run the setup script again (each user will need to run the setup script):

git submodule update --remote
./charon/setup.sh