Skip to content

Commit

Permalink
Merge pull request #75 from moosetechnology/develop
Browse files Browse the repository at this point in the history
V1.0.0
  • Loading branch information
knowbased authored Oct 3, 2024
2 parents 48c9c9c + 89c52cd commit 462d60d
Show file tree
Hide file tree
Showing 113 changed files with 10,141 additions and 1,466 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/ci-dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: CI

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

on:
push:
branches:
- develop

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
smalltalk: [ Moose64-11]
name: ${{ matrix.smalltalk }}
steps:
- uses: actions/checkout@v2
with:
persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal access token.
fetch-depth: 0 # otherwise, there would be errors pushing refs to the destination repository.

- uses: hpi-swa/setup-smalltalkCI@v1
with:
smalltalk-image: ${{ matrix.smalltalk }}

- run: smalltalkci -s ${{ matrix.smalltalk }}
shell: bash
timeout-minutes: 15

- name: Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

2 changes: 1 addition & 1 deletion .github/workflows/ci-moose11.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
smalltalk: [ Moose64-11]
smalltalk: [ Moose64-11 ]
name: ${{ matrix.smalltalk }}
steps:
- uses: actions/checkout@v2
Expand Down
7 changes: 4 additions & 3 deletions .smalltalk.ston
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,16 @@ SmalltalkCISpec {
SCIMetacelloLoadSpec {
#baseline : 'GitLabHealth',
#directory : 'src',
#load : [ 'default', 'Jira' ],
#platforms : [ #pharo ],
#onConflict : #useIncoming,
#onConflict : #useLoaded,
#onUpgrade : #useIncoming
}
],
#testing: {
#packages : [ 'GitLab*', 'GLPH.*', 'GitHub.*' ],
#packages : [ 'GitLab.*', 'GLPH.*', 'GitHub.*', 'GitProject.*', 'BitBucket.*' ],
#coverage : {
#packages : [ 'GitLab.*', 'GLPH.*', 'GitHub.*' ],
#packages : [ 'GitLab.*', 'GLPH.*', 'GitHub.*', 'GitProject.*', 'BitBucket.*' ],
#format : #lcov
}
}
Expand Down
19 changes: 9 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ In the Moose image, in a playground (`Ctrl+O`, `Ctrl+W`), perform:
Metacello new
repository: 'github://moosetechnology/GitProjectHealth:main/src';
baseline: 'GitLabHealth';
onConflict: [ :ex | ex useIncoming ];
onConflict: [ :ex | ex useLoaded ];
onUpgrade: [ :ex | ex useIncoming ];
onDowngrade: [ :ex | ex useLoaded ];
load
Expand Down Expand Up @@ -103,16 +103,19 @@ Here is the metamodel used in this project

![GitProject meta-model png](https://raw.githubusercontent.com/moosetechnology/GitProjectHealth/v1/doc/gitproject.png)

## Connectors

This project comes with connectors to other metamodels to increase its powerfulness.
Explore this part of the [documentation on the main website](https://modularmoose.org/moose-wiki/Users/gitproject-health/getting-started-with-gitproject-health).

## Contributor

This work has been first developed by the [research department of Berger-Levrault](https://www.research-bl.com/)

## Running metrics with docker

## Running metrics with docker
### Running locally

### running locally
```smalltalk
|glphModel glphApi glhImporter beforeExp duringExp usersWithProjects gme|
Expand Down Expand Up @@ -180,7 +183,6 @@ Smalltalk snapshot: true andQuit: true.
```

### deploying with docker


```bash
git clone https://github.com/moosetechnology/GitProjectHealth.git
Expand All @@ -190,13 +192,10 @@ git checkout GLPH-importer-new-changes
sudo docker build -t code-churn-pharo .
sudo docker run code-churn-pharo &
```
locate and retrieve csv output files:

Locate and retrieve csv output files:

```bash
sudo docker ps
sudo docker exec -it <container-id> find / -type f -name 'IA4Code*.csv' 2>/dev/null
```





8 changes: 4 additions & 4 deletions ci/generatePUML.st
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
documentor := FamixUMLDocumentor new.
documentor
model: GLHModel;
beWithStubs;
excludeClasses: { GLHModel. TEntityMetaLevelDependency. Object . GLHEntity . GLHTEntityCreator };
model: GLPHEModel color: Color white;
model: GLHModel color: Color white;
excludeClasses: { GLHModel. TEntityMetaLevelDependency. Object . GLHEntity . GLPHEEntity . GLPHEModel . GLPHETEntityCreator . GLHTEntityCreator . GLHGroupGroup };
generate.

'gitproject.puml' asFileReference writeStreamDo: [ :stream |
FamixUMLPlantUMLBackend new
outputStream: stream;
Expand Down
97 changes: 91 additions & 6 deletions src/BaselineOfGitLabHealth/BaselineOfGitLabHealth.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ BaselineOfGitLabHealth >> baseline: spec [
self defineDependencies: spec.
self definePackages: spec.
self defineGroups: spec.
self defineJiraConnector: spec.
self defineFamixConnector: spec.

spec for: #( #WithoutFamix ) do: [
spec
Expand All @@ -37,16 +39,92 @@ BaselineOfGitLabHealth >> defineDependencies: spec [
with: [ spec repository: 'github://svenvc/NeoJSON/repository' ].
spec
baseline: 'MoreLogger'
with: [ spec repository: 'github://badetitou/MoreLogger:main/src' ]
with: [ spec repository: 'github://badetitou/MoreLogger:main/src' ].
spec
baseline: 'Voyage'
with: [ spec
loads: #('mongo');
repository: 'github://pharo-nosql/voyage/mc' ].
spec
baseline: 'AWS'
with: [
spec repository: 'github://Evref-BL/aws-sdk-smalltalk:master/pharo-repository'
]
]

{ #category : 'baselines' }
BaselineOfGitLabHealth >> defineFamixConnector: spec [

spec
package: 'GitProject-FamixConnector'
with: [ spec requires: #( 'GitProject-FamixConnector-Model' ) ];
package: 'GitProject-FamixConnector-Model';
package: 'GitProject-FamixConnector-Generator'
with: [ spec requires: #( 'GitProject-FamixConnector-Model' ) ];
package: 'GitProject-FamixConnector-Tests'
with: [ spec requires: #( 'GitProject-FamixConnector' ) ]
]

{ #category : 'baselines' }
BaselineOfGitLabHealth >> defineGroups: spec [

spec
group: 'Jira'
with:
#( 'GitProject-JiraConnector' 'GitProject-JiraConnector-Generator'
'GitProject-JiraConnector-Tests' ).

spec
group: 'Famix'
with:
#( 'GitProject-FamixConnector' 'GitProject-FamixConnector-Generator'
'GitProject-FamixConnector-Tests' ).
spec
group: 'Core'
with: #( 'GitLabHealth-Model' 'GitLabHealth-Model-Extension'
'GitLabHealth-Model-Extension-Tests'
'GitLabHealth-Model-Generator' 'GitLabHealth-Model-Inspector'
'GitLabHealth-Model-Visualization'
'GitLabHealth-Model-Importer' 'GitLabHealth-Model-Importer-Tests'
'GitHubHealth-Model-Importer-Tests'
'GLPHExtended-Model' 'GLPHExtended-Model-Tests'
'GLPHExtended-Model-Extension' 'GitLabHealth-Model-Analysis'
'GitLabHealth-Model-Analysis-Tests'
'GitLabHealth-Visualization' 'GitLabProjectHealth-ExtendModel-Generator'
'GitLabProjectHealth-Model-Importer'
'GitLabProjectHealth-Model-Importer-Tests'
'BitBucketHealth-Model-Importer' 'BitBucketHealth-Model-Importer-Tests' ).
spec group: 'default' with: #( 'Core' )
]

{ #category : 'baselines' }
BaselineOfGitLabHealth >> defineJiraConnector: spec [

spec
package: 'GitProject-JiraConnector-Model'
with: [ spec requires: #( 'JiraPharoAPI' ) ];
package: 'GitProject-JiraConnector' with: [
spec requires: #( 'GitProject-JiraConnector-Model'
'JiraPharoAPI' ) ];
package: 'GitProject-JiraConnector-Generator';
package: 'GitProject-JiraConnector-Tests' with: [
spec requires: #( 'GitProject-JiraConnector'
'JiraPharoAPI' ) ].

"dependency"
spec
baseline: 'JiraPharoAPI'
with: [
spec repository: 'github://Evref-BL/Jira-Pharo-API:main/src' ]
]

{ #category : 'baselines' }
BaselineOfGitLabHealth >> definePackages: spec [
"generic"

spec package: 'GitProjectHealth-Model-Importer'.

"gitlab"
spec
package: 'GitLabHealth-Model';
package: 'GitLabHealth-Model-Extension'
Expand All @@ -57,17 +135,23 @@ BaselineOfGitLabHealth >> definePackages: spec [
package: 'GitLabHealth-Model-Inspector'
with: [ spec requires: #( 'GitLabHealth-Model-Visualization' ) ];
package: 'GitLabHealth-Model-Visualization';
package: 'GitLabHealth-Model-Importer'
with: [ spec requires: #( 'NeoJSON' 'MoreLogger' ) ];
package: 'GitHubHealth-Model-Importer'
with: [ spec requires: #( 'NeoJSON' 'MoreLogger' ) ];
package: 'GitLabHealth-Model-Importer' with: [
spec requires:
#( 'NeoJSON' 'MoreLogger' 'GitProjectHealth-Model-Importer' ) ];
package: 'GitHubHealth-Model-Importer' with: [
spec requires:
#( 'NeoJSON' 'MoreLogger' 'GitProjectHealth-Model-Importer' ) ];
package: 'GitLabHealth-Model-Importer-Tests' with: [
spec requires:
#( 'GitLabHealth-Model-Importer' 'GitHubHealth-Model-Importer' ) ].
spec
package: 'GitHubHealth-Model-Importer-Tests'
with: [ spec requires: #( 'GitHubHealth-Model-Importer' ) ].

"bitBucket"
spec package: 'BitBucketHealth-Model-Importer';
package: 'BitBucketHealth-Model-Importer-Tests' with: [ spec requires: #( 'BitBucketHealth-Model-Importer' ) ].

"model extension"
spec
package: 'GLPHExtended-Model' with: [
Expand All @@ -78,7 +162,8 @@ BaselineOfGitLabHealth >> definePackages: spec [
package: 'GLPHExtended-Model-Extension' with: [
spec requires:
#( 'GLPHExtended-Model' 'GitLabHealth-Model' 'GitLabHealth-Model-Extension' ) ];
package: 'GitLabHealth-Model-Analysis';
package: 'GitLabHealth-Model-Analysis'
with: [ spec requires: #( 'Voyage' 'AWS' ) ];
package: 'GitLabHealth-Model-Analysis-Tests'
with: [ spec requires: #( 'GitLabHealth-Model-Analysis' ) ];
package: 'GitLabHealth-Visualization';
Expand Down
Loading

0 comments on commit 462d60d

Please sign in to comment.