From 527c222e776c6b98b513f38bd511b3ae8a5d8330 Mon Sep 17 00:00:00 2001 From: Buck Calabro Date: Sun, 29 May 2016 09:00:16 -0400 Subject: [PATCH] Remove hard coded library in CL; configure for RDi (#6) * Initial commit for a branch to try out RDi and eGit. RDi has the iProjects perspective which allows testing and development, and as a side effect, keeps a copy of the source in a stream file. It is that stream file we're going to piggyback on. * Initial commit; using RDi iProjects * Remove hard coded library * Put library parameter in CL call * Change build.txt to match RDi folder hierarchy. Also, remove PDIR() when done. * Typo in cleanup command. * Add MONMSG to handle errors. Will ignore if message file already exists. Will ignore if message ID already exists. --- .ibmi/.properties | 2 ++ .ibmi/QCLSRC/.properties | 2 ++ .ibmi/QRPGLESRC/.properties | 3 +++ .project | 22 ++++++++++++++++++++++ QCLSRC/SEUEXITCL.CLP | 23 +++++++++++++++++++++++ SEUEXIT.RPGLE => QRPGLESRC/SEUEXIT.RPGLE | 0 SEUEXITCL.CLP | 16 ---------------- build.txt | 10 +++++----- 8 files changed, 57 insertions(+), 21 deletions(-) create mode 100644 .ibmi/.properties create mode 100644 .ibmi/QCLSRC/.properties create mode 100644 .ibmi/QRPGLESRC/.properties create mode 100644 .project create mode 100644 QCLSRC/SEUEXITCL.CLP rename SEUEXIT.RPGLE => QRPGLESRC/SEUEXIT.RPGLE (100%) delete mode 100644 SEUEXITCL.CLP diff --git a/.ibmi/.properties b/.ibmi/.properties new file mode 100644 index 0000000..6442c6c --- /dev/null +++ b/.ibmi/.properties @@ -0,0 +1,2 @@ +#Mon May 23 15:56:19 EDT 2016 +com.ibm.etools.iseries.remotebuild\:ActiveBuildStyle=com.ibm.etools.iseries.remotebuild.style.program diff --git a/.ibmi/QCLSRC/.properties b/.ibmi/QCLSRC/.properties new file mode 100644 index 0000000..f56b7b4 --- /dev/null +++ b/.ibmi/QCLSRC/.properties @@ -0,0 +1,2 @@ +#Mon May 23 16:02:47 EDT 2016 +com.ibm.etools.iseries.projects.core\:ccsid=37 diff --git a/.ibmi/QRPGLESRC/.properties b/.ibmi/QRPGLESRC/.properties new file mode 100644 index 0000000..9fca605 --- /dev/null +++ b/.ibmi/QRPGLESRC/.properties @@ -0,0 +1,3 @@ +#Mon May 23 16:03:15 EDT 2016 +com.ibm.etools.iseries.projects.core\:ccsid=37 +com.ibm.etools.iseries.projects.core\:recordLength=92 diff --git a/.project b/.project new file mode 100644 index 0000000..05a3191 --- /dev/null +++ b/.project @@ -0,0 +1,22 @@ + + + SEUEXIT + + + + + + com.ibm.etools.iseries.perspective.projectBuilder + + + + + com.ibm.etools.iseries.projects.modelValidator + + + + + + com.ibm.etools.iseries.perspective.nature + + diff --git a/QCLSRC/SEUEXITCL.CLP b/QCLSRC/SEUEXITCL.CLP new file mode 100644 index 0000000..54263bd --- /dev/null +++ b/QCLSRC/SEUEXITCL.CLP @@ -0,0 +1,23 @@ +/* Create SEUEXIT message file */ +/* parameter is the name of the library where you want */ +/* to install the message file */ +pgm &tgtlib + +dcl &tgtlib *char 10 + +monmsg cpf2112 /* MSGF already exists */ +monmsg cpf2412 /* MSG already exists */ + +CRTMSGF MSGF(&tgtlib/SEUEXIT) TEXT('SEU Exit program messages') CCSID(*MSGD) + +ADDMSGD MSGID(SEU0001) MSGF(SEUEXIT) MSG('Cursor is not positioned within a + + source statement.') +ADDMSGD MSGID(SEU0002) MSGF(SEUEXIT) MSG('Line split complete.') +ADDMSGD MSGID(SEU0003) MSGF(SEUEXIT) MSG('Line join complete.') +ADDMSGD MSGID(SEU0004) MSGF(SEUEXIT) MSG('Cannot update in Browse mode.') +ADDMSGD MSGID(SEU0005) MSGF(SEUEXIT) MSG('ATTR command processed.') +ADDMSGD MSGID(SEU0006) MSGF(SEUEXIT) MSG('ATTR command not valid for this + + member type.') +ADDMSGD MSGID(SEU0007) MSGF(SEUEXIT) MSG('&1') FMT((*CHAR 80)) + +endpgm diff --git a/SEUEXIT.RPGLE b/QRPGLESRC/SEUEXIT.RPGLE similarity index 100% rename from SEUEXIT.RPGLE rename to QRPGLESRC/SEUEXIT.RPGLE diff --git a/SEUEXITCL.CLP b/SEUEXITCL.CLP deleted file mode 100644 index 9dd2a01..0000000 --- a/SEUEXITCL.CLP +++ /dev/null @@ -1,16 +0,0 @@ -/* Create SEUEXIT message file */ - pgm - - CRTMSGF MSGF(BUCK/SEUEXIT) TEXT('SEU Exit program messages') CCSID(*MSGD) - - ADDMSGD MSGID(SEU0001) MSGF(SEUEXIT) MSG('Cursor is not positioned within a + - source statement.') - ADDMSGD MSGID(SEU0002) MSGF(SEUEXIT) MSG('Line split complete.') - ADDMSGD MSGID(SEU0003) MSGF(SEUEXIT) MSG('Line join complete.') - ADDMSGD MSGID(SEU0004) MSGF(SEUEXIT) MSG('Cannot update in Browse mode.') - ADDMSGD MSGID(SEU0005) MSGF(SEUEXIT) MSG('ATTR command processed.') - ADDMSGD MSGID(SEU0006) MSGF(SEUEXIT) MSG('ATTR command not valid for this + - member type.') - ADDMSGD MSGID(SEU0007) MSGF(SEUEXIT) MSG('&1') FMT((*CHAR 80)) - - endpgm \ No newline at end of file diff --git a/build.txt b/build.txt index 7d9b431..0e3de4c 100644 --- a/build.txt +++ b/build.txt @@ -4,12 +4,12 @@ files: build: ADDLIBLE &INTOLIB - SNDMSG MSG('SEUEXIT requires you to use ''BUCK'' as your INTOLIB due to the hardcode in SEUEXITCL.') TOUSR(*REQUESTER) - CRTSRCPF FILE(&INTOLIB/QSOURCE) RCDLEN(112) - CPYFRMSTMF FROMSTMF('&DIR/SEUEXITCL.CLP') TOMBR('/QSYS.lib/&INTOLIB.lib/QSOURCE.file/SEUEXITCL.mbr') MBROPT(*ADD) + CPYFRMSTMF FROMSTMF('&DIR/QCLSRC/SEUEXITCL.CLP') TOMBR('/QSYS.lib/&INTOLIB.lib/QSOURCE.file/SEUEXITCL.mbr') MBROPT(*ADD) CRTCLPGM PGM(&INTOLIB/SEUEXITCL) SRCFILE(&INTOLIB/QSOURCE) DLTOBJ &INTOLIB/QSOURCE OBJTYPE(*FILE) - CALL &INTOLIB/SEUEXITCL + CALL &INTOLIB/SEUEXITCL ('&INTOLIB') + + CRTBNDRPG PGM(&INTOLIB/SEUEXIT) SRCSTMF('&DIR/QRPGLESRC/SEUEXIT.RPGLE') DBGVIEW(*LIST) REPLACE(*YES) - CRTBNDRPG PGM(&INTOLIB/SEUEXIT) SRCSTMF('&DIR/SEUEXIT.RPGLE') DBGVIEW(*LIST) REPLACE(*YES) \ No newline at end of file + QSH CMD('rm -rf &DIR/') \ No newline at end of file