Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move base plugin files to plugin directory #3157

Merged
merged 9 commits into from Dec 12, 2018

Conversation

Projects
3 participants
@jelovirt
Copy link
Member

commented Nov 22, 2018

Move XSLT and other files from the root directory to org.dita.base directory.

Add plugin URI scheme to allow referencing files in the installation directory. Eclipse's plugin URI scheme has been used as a reference for the design. While plugin URIs can be used to address plugin files, the old plugin URIs should be used to reference plugin files.

@jelovirt

This comment has been minimized.

Copy link
Member Author

commented Nov 23, 2018

@robander Now the directory structure is approximately (omitting some files that do not play any role in this change):

bin/
└── ...
build.xml  # this is the start Ant script, imports plugins/org.dita.base/build.xml
config/
├── CatalogManager.properties
├── configuration.properties
├── log4j.properties
├── logback.xml
├── messages_en_US.properties
├── org.dita.dost.platform/
│   └── plugin.properties
└── plugins.xml
doc/
└── ...
docsrc/
└── ...
integrator.xml
lib/
└── ...
plugins/
└──  org.dita.base/
    ├── build.xml  # this is generated in integration and contains imports from other plugins
    ├── build_init.xml
    ├── build_preprocess.xml
    ├── build_preprocess2.xml
    ├── catalog-dita.xml
    ├── config/
        └── messages.xml
    ├── plugin.xml
    └── xsl/
        └── ...

Are you able to test this with your plugins?

@robander

This comment has been minimized.

Copy link
Member

commented Nov 26, 2018

@jelovirt yes - can test in the next couple of days.

@jelovirt jelovirt force-pushed the feature/base_plugin branch from 5702b39 to 4d104b1 Dec 6, 2018

@jelovirt jelovirt added this to In progress in 3.3 via automation Dec 6, 2018

@jelovirt jelovirt self-assigned this Dec 6, 2018

@jelovirt jelovirt requested a review from robander Dec 6, 2018

jelovirt added some commits Nov 20, 2018

Move base plugin files to plugin directory
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Fix relative catalog entries and catalog references
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Fix distribution build
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Fix XSpec stylesheet paths
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Move messages to base plugin
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Fix plugin configuration for tests and integrator test
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
Move init target to base plugin because it contains generated content
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>

@jelovirt jelovirt force-pushed the feature/base_plugin branch from 66efc69 to 401d275 Dec 10, 2018

@robander

This comment has been minimized.

Copy link
Member

commented Dec 10, 2018

Tested our plugins. Some require migration unrelated to this PR (PDF still needs minor changes to be up to date with 3.2), but no issues related to file imports. Our styled HTML / plain text output both look good.

Also confirmed that error messages from our plugins are showing up in the messages.xml file in the new spot (as expected, but seemed worth checking).

I'm sure there are other things I could look at but the basic test looks good for core DITA-OT transform types, as well as for some of our more complex styled plugins.

<!-- Initialize DITA-OT base directory -->
<dirname property="ant.file.DOST.dir" file="${ant.file.DOST}" />
<property name="dita.dir" location="${ant.file.DOST.dir}"/>
<!-- XXX Is this ever used? -->

This comment has been minimized.

Copy link
@robander

robander Dec 10, 2018

Member

I see dita.dir used in tons of plugins and our generated build.xml uses it quite a bit ... but I'm guessing this is a question about the second definition? I assume that second definition wouldn't be used...

3.3 automation moved this from In progress to Reviewer approved Dec 10, 2018

@robander

This comment has been minimized.

Copy link
Member

commented Dec 10, 2018

Issues on my machine prevented me from building a real copy of the dist to test, so I built without docs -- should double check that when the full dist build is created, we end up with a valid map from docscr/userguide.ditamap. The generated messages topic in particular probably needs a change related to this.

Move messages back to root config directory
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>

3.3 automation moved this from Reviewer approved to Needs review Dec 12, 2018

@jelovirt

This comment has been minimized.

Copy link
Member Author

commented Dec 12, 2018

Moved messages_template.xml to root config directory. I'm not sure which files should be in the root config instead of base plugin's config directory. We may need to move them about some more later on.

@infotexture are you able to test this too? I verified that the dist build with docs works and that building the docs with dita command from the distribution package works too. Do you have additional ways of building that might be affected by this change?

Add support for platform URI scheme
Signed-off-by: Jarno Elovirta <jarno@elovirta.com>
@infotexture

This comment has been minimized.

Copy link
Member

commented Dec 12, 2018

Successfully tested distribution build from a clean worktree:

git worktree add -b test/base_plugin_dist ../dita-ot.dist.worktree feature/base_plugin

cd ../dita-ot.dist.worktree/

git submodule update --init --recursive
./gradlew
./gradlew dist

Verified that docs site builds still work.

3.3 automation moved this from Needs review to Reviewer approved Dec 12, 2018

@infotexture

This comment has been minimized.

Copy link
Member

commented Dec 12, 2018

@jelovirt 👍 LGTM.

@jelovirt jelovirt merged commit 77bdcd3 into develop Dec 12, 2018

4 checks passed

DCO DCO
Details
WIP Ready for review
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

3.3 automation moved this from Reviewer approved to Done Dec 12, 2018

@jelovirt jelovirt deleted the feature/base_plugin branch Jan 12, 2019

@jelovirt jelovirt added this to the 3.3 milestone Jan 21, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.