home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / games / volume16 / nethack31 / part104 / rebuild.sh
Linux/UNIX/POSIX Shell Script  |  1993-02-06  |  3KB  |  113 lines

  1. #!/bin/sh
  2. #
  3. # small sh script to concatenate the files that were split for posting
  4. #
  5. TOP=`pwd`
  6. DAT=$TOP/dat
  7. DOC=$TOP/doc
  8. SRC=$TOP/src
  9. AMIGA=$TOP/sys/amiga
  10. MAC=$TOP/sys/mac
  11. SHARE=$TOP/sys/share
  12.  
  13. # dat
  14. cd $DAT
  15. cat quest.tx1 quest.tx2 > quest.txt
  16. if test -f quest.txt
  17. then echo "'quest.txt' made"; rm quest.tx1 quest.tx2
  18. else echo "'quest.txt' not made - do cat by hand"
  19. fi
  20. cd $TOP
  21.  
  22. # doc
  23. cd $DOC
  24. cat Guidebook.te1 Guidebook.te2 > Guidebook.tex
  25. cat Guidebook.uu1 Guidebook.uu2 | uudecode
  26. if test -f Guidebook.tex
  27. then echo "'Guidebook.tex' made"; rm Guidebook.te1 Guidebook.te2
  28. else echo "'Guidebook.tex' not made - do cat by hand"
  29. fi
  30. if test -f Guidebook.txt
  31. then echo "'Guidebook.txt' made"; rm Guidebook.uu1 Guidebook.uu2
  32. else echo "'Guidebook.txt' not made - do cat and uudecode by hand"
  33. fi
  34. cd $TOP
  35.  
  36. # src
  37. cd $SRC
  38. cat mhitu.c1 mhitu.c2 > mhitu.c
  39. cat monst.c1 monst.c2 monst.c3 > monst.c
  40. cat shk.c1 shk.c2 > shk.c
  41. cat sp_lev.c1 sp_lev.c2 > sp_lev.c
  42. cat trap.c1 trap.c2 > trap.c
  43. cat vision.c1 vision.c2 > vision.c
  44. cat zap.c1 zap.c2 > zap.c
  45. if test -f mhitu.c
  46. then echo "'mhitu.c' made"; rm mhitu.c1 mhitu.c2
  47. else echo "'mhitu.c' not made - do cat by hand"
  48. fi
  49. if test -f monst.c
  50. then echo "'monst.c' made"; rm monst.c1 monst.c2 monst.c3
  51. else echo "'monst.c' not made - do cat by hand"
  52. fi
  53. if test -f shk.c
  54. then echo "'shk.c' made"; rm shk.c1 shk.c2
  55. else echo "'shk.c' not made - do cat by hand"
  56. fi
  57. if test -f sp_lev.c
  58. then echo "'sp_lev.c' made"; rm sp_lev.c1 sp_lev.c2
  59. else echo "'sp_lev.c' not made - do cat by hand"
  60. fi
  61. if test -f trap.c
  62. then echo "'trap.c' made"; rm trap.c1 trap.c2
  63. else echo "'trap.c' not made - do cat by hand"
  64. fi
  65. if test -f vision.c
  66. then echo "'vision.c' made"; rm vision.c1 vision.c2
  67. else echo "'vision.c' not made - do cat by hand"
  68. fi
  69. if test -f zap.c
  70. then echo "'zap.c' made"; rm zap.c1 zap.c2
  71. else echo "'zap.c' not made - do cat by hand"
  72. fi
  73. cd $TOP
  74.  
  75. # amiga
  76. cd $AMIGA
  77. cat wb.c1 wb.c2 > wb.c
  78. cat winami.c1 winami.c2 > winami.c
  79. if test -f wb.c
  80. then echo "'wb.c' made"; rm wb.c1 wb.c2
  81. else echo "'wb.c' not made - do cat by hand"
  82. fi
  83. if test -f winami.c
  84. then echo "'winami.c' made"; rm winami.c1 winami.c2
  85. else echo "'winami.c' not made - do cat by hand"
  86. fi
  87. cd $TOP
  88.  
  89. # mac
  90. cd $MAC
  91. cat NHsound.hq1 NHsound.hq2 NHsound.hq3 NHsound.hq4 > NHsound.hqx
  92. cat macwin.c1 macwin.c2 > macwin.c
  93. if test -f NHsound.hqx
  94. then echo "'NHsound.hqx' made"; rm NHsound.hq1 NHsound.hq2 NHsound.hq3 NHsound.hq4
  95. else echo "'NHsound.hqx' not made - do cat by hand"
  96. fi
  97. if test -f macwin.c
  98. then echo "'macwin.c' made"; rm macwin.c1 macwin.c2
  99. else echo "'macwin.c' not made - do cat by hand"
  100. fi
  101. cd $TOP
  102.  
  103. # share
  104. cd $SHARE
  105. cat lev_yacc.c1 lev_yacc.c2 > lev_yacc.c
  106. if test -f lev_yacc.c
  107. then echo "'lev_yacc.c' made"; rm lev_yacc.c1 lev_yacc.c2
  108. else echo "'lev_yacc.c' not made - do cat by hand"
  109. fi
  110. cd $TOP
  111.  
  112. exit 0
  113.