EDG Studio: Best practice for editing files and Git integration

28 views
Skip to first unread message

Andrew Arnold

unread,
Jul 23, 2024, 2:42:31 PMJul 23
to TopBraid Suite Users
Hi,  I'm learning my way through config of git integration in Studio in conjunction with using the File edit tools.  

GIT integration
Once configured, Studio exports a ttl and publishes  it to a local folder that's configured as a git repository.   The user guide simply says to specify a local folder where Studio posts ttls'....All good there...

File Edit and source code control
I'm also interested in putting SPARQL queries and ADS scripts under source control whether or not they are integrated into a collection for example by embedding a script into a resource action.

The Studio video tutorial on YouTube  shows the creation of a workspace sub folder where new files are saved.    

Two questions.:

1. Is it possible to save a script or SPARQL query to a file, integrated with the File Edit capabilities ?  I haven't seen how to accomplish this...

2. Best practice: does Topquadrant recommend config of the local git repository within the workspace folder structure, for example the workspace sub-folder that's described in the Studio video tutorial?

Thanks!

Andrew Arnold

unread,
Jul 23, 2024, 3:13:26 PMJul 23
to TopBraid Suite Users
Also... I just noted that the GIT integration export commands aren't available for ontologies or taxonomies ?

Why?

Thx!

David Price

unread,
Jul 24, 2024, 7:35:26 AMJul 24
to 'Felix Sasaki' via TopBraid Suite Users
Hi Andrew,

No real “answers”, but some thoughts below.

On 23 Jul 2024, at 19:42, Andrew Arnold <jaar...@gmail.com> wrote:

Hi,  I'm learning my way through config of git integration in Studio in conjunction with using the File edit tools.  

GIT integration
Once configured, Studio exports a ttl and publishes  it to a local folder that's configured as a git repository.   The user guide simply says to specify a local folder where Studio posts ttls'....All good there...

File Edit and source code control
I'm also interested in putting SPARQL queries and ADS scripts under source control whether or not they are integrated into a collection for example by embedding a script into a resource action.

The Studio video tutorial on YouTube  shows the creation of a workspace sub folder where new files are saved.    

Two questions.:

1. Is it possible to save a script or SPARQL query to a file, integrated with the File Edit capabilities ?  I haven't seen how to accomplish this...

FYI there is a ticket to make SPARQL Library Queries “deployable” though so should be better in 8.1, but I think that has to be exported and importer into where used. 

Not 100% sure of your use case but … you can save an RDF file of SPARQL that you could then copy and paste into the SPARQL Panel. I just made an ontology and saved some SPARQL as a constraint that is readable using Files if exported to TTL, deleted and loaded back into the workspace somewhere:


Screenshot 2024-07-24 at 11.57.57.png



2. Best practice: does Topquadrant recommend config of the local git repository within the workspace folder structure, for example the workspace sub-folder that's described in the Studio video tutorial?

Not claiming that there is a single “TQ recommendation” on this topic as it depends a lot on exactly what you are doing, and what technology you are using. 

Being a PS team member, I also have many workspaces (E.g. one per customer/project per EDG release - I have about 30 at the moment) while that might not be true for you. So, my usage may be “unusual”.

For my projects that include software projects (e.g. with older SWP tech in them) I need everything possible so:

  • When creating a new workspace for an EDG Studio install (one per project per release of EDG) I add symbolic links to the folders in my local git clone (never a whole repo in my case, as I need to 100% control what is visible to each Studio installation).  
  • use git Desktop app for Mac to handle branch, push, pull.
  • I often browse and edit TTL using Visual Studio too, though, and that makes a difference. BBEdit sometimes too as it has a very nice diff function.
  • EDG Files also works in this config

I know others who only ever edit using EDG Files function, so might have a different preferred config.

Personally, I do not directly edit anything using Files that is under git control. I always export sorted turtle and use the git diff before save or push. I like to see every detailed change before merge, but maybe that’s unusual.

FWIW there are also times when I do not use git at all and instead use an “all collections” approach. Sometimes I need two or three Studio installs running with different versions of the same graphs. If I mange them as EDG collections, then a single export zip means I can copy everything for a project to a new workspace in one easy step. This also works great when collaborating with less technical colleagues or sharing with customers who would never use git.

By export zip I mean “Zip File without system graphs”. Much better than trig IMO as it’s just a zip of TTL files.

Cheers,
David



Thanks!

--
The topics of this mailing list include TopBraid EDG and related technologies such as SHACL.
To post to this group, send email to topbrai...@googlegroups.com
---
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/d3400c71-4e34-44fc-b600-52e706dd72fan%40googlegroups.com.

David Price, Semantic Solution Architect

Reply all
Reply to author
Forward
0 new messages