Git Product home page Git Product logo

pldev-project-helpers's Introduction

PL/SQL Developer (Allround Automations) project file helper scripts

The PL/SQL Developer project files come with old-school INI-based structure with rather unfortunate project items assignment to item groups/folders based on positional ID. If an item (SQL/PLSQL script file) gets added/removed anywhere "in/from the middle" of the existing project items, all item groups/folders in the INI file are heavily rewritten with completely different item IDs due to their positional nature.

These project files are not easily manageable under a version control system. The problem is somewhat bearable when only one team member manages a project file - file can be committed anytime, although comparison of differences is perhaps of lesser use.

The problem gets more pronounced when there are multiple maintaners of the project file; and it gets completely unbearable as soon as branching/merging gets introduced to the solution that uses the PL/SQL Developer project files. Merging conflicts in these files could become your daily (or even hourly) nightmare.

Hence I coded my own few helper scripts around this (and a few others) problem.

merge_pldev_prj.sh

A simple preprocess->process->postprocess shell script for merging the PL/SQL Developer project files. Run it, argument-less, from command line and see its simple usage help. I believe it's self-explanatory.

Before actually using this helper you may need to open the merge_pldev_prj.sh and edit the line that follows

# set up path to the TortoiseMerge.exe here...

Depends on:

  • bash, gawk, sed, tr (perhaps from https://www.cygwin.com/),
  • TortoiseMerge,
  • dos2unix utility for converting DOS/Win EOLNs (CR+LF) to Unix EOLNs (LF).

order_pldev_project_items.awk

Order project items alphabetically. It's great, though purely optional, before an actual merging.

Usage:

gawk -f "${PathToPldevHelpers}/order_pldev_project_items.awk" < project_file.prj > project_file_ordered.prj

... or...

dos2unix < project_file.prj | gawk -f "${PathToPldevHelpers}/order_pldev_project_items.awk" > project_file_ordered.prj

cross_check_PRJ_vs_filesystem.sh

PL/SQL Developer does not check for existence of project items on the filesystem. Use this script to check all project files (*.prj) in your current directory for existence of their items on the filesystem and vice versa.

All project items that do not exist on filesystem, are automatically removed from the (resulting) project file.

All filesystem items (in the whole subtree of your "current directory") are automatically added into the (resulting) project file under the "unsorted" item group.

Depends on:

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.