Guest User

Untitled

a guest
Feb 24th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.69 KB | None | 0 0
  1. clear
  2. echo "------------------"
  3. echo " JavaGUI V-1.0"
  4. echo "------------------"
  5. echo
  6. echo "******************************************"
  7. echo ":To start application input User name:"
  8. echo "******************************************"
  9. read j
  10. cd /home/$j
  11. clear
  12. echo "------------------"
  13. echo " JavaGUI V-1.0"
  14. echo "------------------"
  15. echo
  16. ls
  17. echo
  18. echo "***********************************************************************"
  19. echo "Now locate the folder from above list where you put the javaGUI.sh file"
  20. echo "***********************************************************************"
  21. read l
  22. clear
  23. echo "------------------"
  24. echo " JavaGUI V-1.0"
  25. echo "------------------"
  26. echo
  27. ls
  28. echo
  29. echo "******************************************************"
  30. echo ":Now locate .java containing file from the list above:"
  31. echo "******************************************************"
  32. read k
  33. cd $k
  34. clear
  35. while [ $ch==10 ]
  36. do
  37. clear
  38. echo "------------------"
  39. echo " JavaGUI V-1.0"
  40. echo "------------------"
  41. echo
  42. echo "''''''''''''''''''"
  43. echo " Menu"
  44. echo "''''''''''''''''''"
  45. echo "**********************************"
  46. echo "1.Create/Edit a java application"
  47. echo "**********************************"
  48. echo "2.Delete a java application"
  49. echo "**********************************"
  50. echo "3.Compile & run a java application"
  51. echo "**********************************"
  52. echo "4.Quit"
  53. echo "**********************************"
  54. echo "----------------------------------"
  55. echo "Enter your choice(1-4):"
  56. read ch
  57. case $ch in
  58. 1)
  59. clear
  60. cd /home/$j/$k
  61. ls
  62. echo ":Select an application to edit or enter new application name:"
  63. read a
  64. nano $a
  65. ;;
  66. 2)
  67. cd /home/$j/$k
  68. clear
  69. ls
  70. echo
  71. echo ":Select an application to delete:"
  72. read b
  73. rm $b
  74. ;;
  75. 3)
  76. cd /home/$j/$k
  77. clear
  78. ls
  79. echo
  80. echo ":Select an application to compile and run:"
  81. read c
  82. javac $c 2> h
  83.  
  84. if [ -s h ]
  85. then
  86. echo
  87. echo "Your program is incomplete or failed to compile.Please check again!!"
  88. echo "--------------------------------------------------------------------"
  89. cat h
  90. else
  91. echo "Your program compiled!!Now re-enter the app name to run it:"
  92. echo "-----------------------------------------------------------"
  93. fi
  94. read d
  95. clear
  96. echo "Your program starts from here"
  97. echo "*****************************"
  98. echo
  99. java $d
  100. ;;
  101. 4)
  102. kill -9 $PPID
  103. ;;
  104. *)
  105. echo "Invalid choice!!Try again."
  106. ;;
  107. esac
  108. echo
  109. echo
  110. echo "---Press Anykey to return to menu---"
  111. read ch
  112. done
  113.  
  114. #*****INSTALLATION INSTRUCTION*****
  115. #1.After downloading this zip file extract it in home folder.
  116. #2.Then rename the extracted folder to "As you like"
  117. #3.open terminal & type without '#'
  118. #cd /home/**user name of computer**/**as you named the extracted folder**
  119. #4.Then type
  120. # sudo chmod +x JavaGUI.sh & type password
  121. #5.Now close window go to desktop
  122. #6.Create a launcher
  123. #ENJOY!
Add Comment
Please, Sign In to add comment