xowa_maven_files.sh 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. echo "* XOWA: regen xowa_maven root"
  2. rm -rf ./src/xowa_maven
  3. mkdir -p ./src/xowa_maven
  4. echo "* XOWA: copying maven pom.xml and build.xml"
  5. cp -rf ./pom.xml ./src/xowa_maven/
  6. cp -rf ./build.xml ./src/xowa_maven/
  7. echo "* XOWA: copy res to xowa_maven"
  8. cp -R$verbose ./src/xowa/res ./src/xowa_maven
  9. echo "* XOWA: copy user / bin to runtime locations"
  10. cp -R$verbose ./src/xowa_maven/res/user ./src/xowa_maven
  11. cp -R$verbose ./src/xowa_maven/res/bin ./src/xowa_maven
  12. echo "* XOWA: prepare source directories"
  13. mkdir -p ./src/xowa_maven/src/main/java/gplx
  14. mkdir -p ./src/xowa_maven/src/test/java/gplx
  15. echo "* XOWA: create mavenize_xowa function"
  16. mavenize_xowa ()
  17. {
  18. echo "* XOWA: mavenizing $1"
  19. # main <- all non test files
  20. find $1 -depth -type f \
  21. \( ! -name '*_tst.java' \
  22. -a ! -name '*_fxt.java' \
  23. -a ! -name '*_mok.java' \
  24. -a ! -name '*Test.java' \
  25. \) \
  26. -exec cp --parents -pr$verbose '{}' './src/xowa_maven/src/main/java/gplx/' ';'
  27. # main <- all test files
  28. find $1 -depth -type f \
  29. \( -name '*_tst.java' \
  30. -o -name '*_fxt.java' \
  31. -o -name '*_mok.java' \
  32. -o -name '*Test.java' \
  33. \) \
  34. -exec cp --parents -pr$verbose '{}' './src/xowa_maven/src/test/java/gplx/' ';'
  35. }
  36. # package: baselib
  37. # mavenize_xowa ./src/xowa/baselib/ # commenting out b/c of ClassName collision between baselib
  38. # package: core
  39. mavenize_xowa ./src/xowa/100_core/
  40. # package: gfml
  41. mavenize_xowa ./src/xowa/110_gfml/src_100_tkn/gplx/
  42. mavenize_xowa ./src/xowa/110_gfml/src_200_type/gplx/
  43. mavenize_xowa ./src/xowa/110_gfml/src_300_gdoc/gplx/
  44. mavenize_xowa ./src/xowa/110_gfml/src_400_pragma/gplx/
  45. mavenize_xowa ./src/xowa/110_gfml/src_500_build/gplx/
  46. mavenize_xowa ./src/xowa/110_gfml/src_600_rdrWtr/gplx/
  47. mavenize_xowa ./src/xowa/110_gfml/tst/gplx/
  48. # package: 140_dbs
  49. mavenize_xowa ./src/xowa/140_dbs/src/gplx/
  50. # mavenize_xowa ./src/xowa/140_dbs/tst/gplx/ # tests in this folder require mysql and postgres server
  51. # package: gfui
  52. mavenize_xowa ./src/xowa/150_gfui/src/gplx/
  53. # package: xowa
  54. mavenize_xowa ./src/xowa/400_xowa/src/gplx/
  55. # package: gflucene
  56. mavenize_xowa ./src/xowa/gplx.gflucene/src/gplx/