Code Monkey home page Code Monkey logo

vdom-types-counter's Introduction

VDOM types counter

This script is used to count VDOM types that is used in an applications.

Dependencies

The python script requires the openpyxl library for Excel file operations.

Main Script

The main script is count_types.sh and expects two arguments:

  1. Path to the types directory.
  2. Path to the compiled apps directory.

Usage:

./count_types.sh <path_to_VDOMserver_types_directory> <path_to_app\.tmp\pack>

The script first checks if the correct number of arguments are provided. It then delegates tasks to other scripts, namely process_types.sh, pattern_search.sh, and types_report.py.

process_types.sh

This script is designed to traverse a specified directory, searching for files named type.xml. For each type.xml file found, the script extracts the value within the <Name> tag and associates it with the name of the containing folder - type guid. The final output is a JSON representation of the folder names and their corresponding <Name> values from the type.xml files.

Usage:

bash ./process_types.sh <path_to_types_directory>

pattern_search.sh

This script is tailored to search through XML files within a specified directory, looking for matches based on a provided grep pattern using RegEx. For each XML file, the script displays the filename (deleting "_compiled.xml" suffix) followed by unique matches of the pattern.

Usage:

bash ./pattern_search.sh <path_to_compiled_apps_directory> '<grep pattern using RegEx>

types_report.py

This Python script generates a report based on the outputs of the previous scripts. Simply run it after the main script to get the report. Once executed, it will generate an Excel file named report.xlsx in the same directory.

Usage:

python types_report.py

vdom-types-counter's People

Contributors

astyd256 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.