Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/modernizing/merry
a legacy Java system build migration toolbox, support ant to maven, find lost dep in nexus...
https://github.com/modernizing/merry
Last synced: about 2 months ago
JSON representation
a legacy Java system build migration toolbox, support ant to maven, find lost dep in nexus...
- Host: GitHub
- URL: https://github.com/modernizing/merry
- Owner: modernizing
- License: mpl-2.0
- Created: 2020-06-07T10:37:17.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2022-02-12T07:54:39.000Z (almost 3 years ago)
- Last Synced: 2024-05-20T03:21:14.111Z (8 months ago)
- Language: Go
- Homepage:
- Size: 1.45 MB
- Stars: 10
- Watchers: 1
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-modernization - Merry
README
# Going Merry
> a legacy Java system build migration toolbox, support ant to maven, find lost dep in nexus...
![Go](https://github.com/phodal/merry/workflows/Go/badge.svg)
[![Build Status](https://travis-ci.org/phodal/merry.svg?branch=master)](https://travis-ci.org/phodal/merry)
[![codecov](https://codecov.io/gh/phodal/merry/branch/master/graph/badge.svg)](https://codecov.io/gh/phodal/merry)
![GitHub go.mod Go version](https://img.shields.io/github/go-mod/go-version/phodal/merry)
[![Maintainability](https://api.codeclimate.com/v1/badges/77b3f3f4a2444b33dc16/maintainability)](https://codeclimate.com/github/phodal/merry/maintainability)Refactor Tool -> [Coca](https://github.com/phodal/coca)
Online Example for Call Analysis: [https://modernizing.github.io/merry/demo](https://modernizing.github.io/merry/demo)
Online Screenshots:
![Merry](docs/screenshots/merry.png)
Feature lists:
```bash
Available Commands:
boom generate pom.xml from build.xml
call show call graph for packages
checksum checksum file md5
dupsearch build maven pom from all jars file
fix fix jar naming issue
help Help about any command
manifest manifest query & map tools
map generate map.csv from jar
pom generate pom file from jar file
version version```
## Usage
1. install
```bash
go get -u github.com/phodal/merry
```2. generate `pom.xml` from `build.xml`
```bash
merry boom
```3. search package lost in nexus
```bash
merry dupsearch
```4. map file example
format: `{origin},{GroupId},{ArtifactId},{VersionId}`
```
origin,groupid,artifactId,version
org.springframework.transaction,org.springframework,transaction.org.springframework.transaction,2.5.6.SEC01
javax.servlet,javax.servlet,javax.servlet,2.4.0
edu.emory.mathcs.backport.java.util,edu.emory.mathcs.backport,com.springsource.edu.emory.mathcs.backport,3.1.0
edu.emory.mathcs.backport.java.util.concurrent,edu.emory.mathcs.backport,com.springsource.edu.emory.mathcs.backport,3.1.0
edu.emory.mathcs.backport.java.util.concurrent.atomic,edu.emory.mathcs.backport,com.springsource.edu.emory.mathcs.backport,3.1.0
edu.emory.mathcs.backport.java.util.concurrent.helpers,edu.emory.mathcs.backport,com.springsource.edu.emory.mathcs.backport,3.1.0
edu.emory.mathcs.backport.java.util.concurrent.locks,edu.emory.mathcs.backport,com.springsource.edu.emory.mathcs.backport,3.1.0
org.apache.commons.dbcp,org.apache.commons,com.springsource.org.apache.commons.dbcp,1.2.2.osgi
org.apache.commons.logging,commons-logging,commons-logging,1.1.1
org.slf4j,org.slf4j,org.slf4j,1.5.1
```### Manifest
```bash
Usage:
merry manifest [flags]Flags:
-e, --excludeSource is with exclude source file
-x, --extract extract manifest file from jar
-f, --filter string filter
-h, --help help for manifest
-m, --merge is merge package
-p, --path string path (default ".")
-s, --scan scan manifest file to graphviz
-v, --version show manifest version info of jar
```examples:
```bash
merry manifest -s -x -f org.eclipse.equinox -p ~/sdk/equinox-SDK-4.15/plugins
```### Generate Pom from jars
```bash
merry pom -p _fixtures/demo -m _fixtures/map/map.csv
```### Call Graph by Manifest.MF
```bash
Flags:
-h, --help help for call
-m, --map string map file
-p, --path string path (default ".")
-s, --server with server
```full steps:
```bash
merry manifest -s -p ~/sdk/apache-karaf-4.2.9/lib/boot -x
merry map -p ~/sdk/apache-karaf-4.2.9/lib/boot
merry call -p ~/sdk/apache-karaf-4.2.9/lib/boot -m map.csv
```results:
![Call Graph](docs/screenshots/call-example-karaf.svg)
show only one line with `strict`
```graphviz
strict digraph G {
a -> b [ label = "foo" ];
a -> b [ label = "bar" ];
}
```#### Call Server
cmd: `merry call -s`
`merry` will read `manifest-map.json` and start to [http://localhost:3000](http://localhost:3000):
example: [https://phodal.github.io/merry/demo](https://phodal.github.io/merry/demo)
## Todo
Todo:
- [x] Ant to Maven
- [x] dependencies convert
- [x] Checksum File
- [x] Unzip file
- [x] Parse Manifest
- [x] Dup Search. search all jars and find not in nexus package
- [x] POM generate dep graph
- [x] basic graph
- [x] go server
- [x] visual with circle [Hierarchical Edge Bundling](https://observablehq.com/@d3/hierarchical-edge-bundling)
- [x] jar auto rename
- [x] use POM rename jar
- [x] custom version
- [x] configurable
- [x] from jar to map.csvLicense
---@ 2020 A [Phodal Huang](https://www.phodal.com)'s [Idea](http://github.com/phodal/ideas). This code is distributed under the MPL license. See `LICENSE` in this directory.