Closed Azquelt closed 9 months ago
I think we really should get rid of api/src/ide
(which contains jboss_community_formatter.xml
). The ide-config
module was added by @manovotn in #731 (copied from Weld, which coped it from Quarkus, where it was an original creation, albeit derived -- if not just copied -- from the default Eclipse format IIUC).
I think we really should get rid of
api/src/ide
(which containsjboss_community_formatter.xml
). Theide-config
module was added by @manovotn in #731 (copied from Weld, which coped it from Quarkus, where it was an original creation, albeit derived -- if not just copied -- from the default Eclipse format IIUC).
True, +1 for removing that; I didn't even know it's there, else I'd have removed that as part of the PR you linked :)
I was a bit unsure whether the policy
format supports /* ... */
comments, because the documentation doesn't mention comments explicitly, it just shows //
comments in some examples. However, the implementation of sun.security.provider.PolicyParser
shows that both comment styles are supported, so I guess we should be fine.
CONTRIBUTING.adoc
When reviewing, please particularly check that I haven't added a copyright header to something that shouldn't have one. The areas I wasn't sure about were:
docs
directory which builds https://jakartaee.github.io/cdi/.github
directryide-support
andjboss_community_formatter.xml
- I don't know how these were developed, they may have come form another project and probably started from the defaults of the the software that creates them?I haven't changed any headers on existing files and I've used the format that includes the original author's name since some of the files pre-date involvement with the Eclipse Foundation.
Script used to generate headers
It's a bit rough, some files needed fixed up by hand, particularly XML ones since the ` tmp.txt mv tmp.txt "$2" } missing_extensions=() for F in $(grep -h ????? target/rat.txt | sed -e 's| !????? ||') ; do data=$(git log --format="%ae %as" $F | tail -1) if [[ $data =~ redhat || $data =~ starksm || $data =~ pmuir || $data =~ antoine || $data =~ marlow || $data =~ gegastaldi || $data =~ ladicek ]] ; then company="Red Hat, Inc." elif [[ $data =~ ibm ]] ; then company="IBM Corp." else echo "No known owner for $F, who is $data" fi year=$(echo $data | cut -d ' ' -f 2 | cut -d '-' -f 1) filename=$(basename "$F") extension="${filename##*.}" if [[ $extension == asciidoc || $extension == adoc ]] ; then header=$(format_header "////" "" "////" "$company" "$year") elif [[ $extension == xml || $extension == html || $extension == md ]] ; then header=$(format_header "" "$company" "$year") elif [[ $extension == yml || $extension == Gemfile || $extension == importorder ]] ; then header=$(format_header "" "# " "" "$company" "$year") elif [[ $extension == java || $extension == policy ]] ; then header=$(format_header "/*" " * " "\\ */" "$company" "$year") else header="Unknown format: $extension" missing_extensions+=("$extension") fi add_header "$header" "$F" done declare -A uniq_ext for ext in "${missing_extensions[@]}" do uniq_ext[$ext]=0 done echo "missing extensions: " "${!uniq_ext[@]}" ```Fixes #741