Skip to main content

Use this to remove unused CMS in your ivy project

Project description

Ivy Used CMS Scanner

About

Large AxonIvy projects usually have huge number amount of CMSs, and overtime, after countless times of adding, updating and removing the CMSs, there will be zoombie CMSs in your code base.

The idea of this tool is pretty simple:

In each project:

  • List out all *.data and co.meta files
  • Group the *.data files with their corresponding co.meta file
  • Search the CMS in [*.java, *.drl, *.xhtml, *.mod] files using > - CMS's path (example: /fintech/soba/authentication/message/accessdenied)
  • If no result found -> CMS is not being used

WARNING: If the CMS is not hard-coded, it will be deleted.

Installation

pip install rich

pip install ivy-cms-unused-scanner

Usage

Create a Python script

from cms_scanner import cms_scanner
from rich.prompt import Prompt
import os

if __name__ == '__main__':
    path = Prompt.ask("Please enter the absolute path to your project")
    console.print("Process [bold purple]" + path)
    # move to the project folder
    os.chdir(path)
    cleaner = cms_cleaner()
    cleaner.get_all_cms()
    cleaner.get_unused_cms()

Run the script

python cms_scanner.py

Example output:

Failed

Success

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ivy_cms_unused_scanner-0.0.5.tar.gz (3.8 kB view hashes)

Uploaded Source

Built Distribution

ivy_cms_unused_scanner-0.0.5-py3-none-any.whl (5.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page