Win a copy of TensorFlow 2.0 in Action this week in the Artificial Intelligence and Machine Learning forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Paul Clapham
  • Bear Bibeault
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • salvin francis
  • Scott Selikoff
  • fred rosenberger

How to create .java files on Mac?

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,  I'm really excited about the excellent OCA Study Guide ( JAVA_OCA_Oracle_Certified_Associate_Java_SE_8_Programmer_I_Study_Guide_Exam_1Z0_808 )! However, I'm stuck. In Chapter 1 (Java Building Blocks) on p.14, in Compiling Code with Packages, it says: 'You’ll learn Java much more easily by using the command line to compile and test your examples. '

I totally agree! Then it says:
'Follow this example to make sure you know how to use the command line. If you have any problems following this procedure, post a question in the Beginning Java forum at CodeRanch (www.coderanch.com/forums/f-33/java)...'

On next page I saw:
Mac/Linux Setup Create the two files:
/tmp/packagea/ClassA.java
/tmp/packageb/ClassB.java

My problem is: How do I create .java files on Mac (with a specific path as above)? Which app can or should I use?

Sorry this is such a basic question (and I have no error message because I wasn't able to try anything). Thanks so much in advance for your help!

 
Saloon Keeper
Posts: 6645
161
Android Mac OS X Firefox Browser VI Editor Tomcat Server Safari
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch.

This topic is age old, but I think it is still valid: https://coderanch.com/t/111632/os/Java-MAC-OS

And no, I wouldn't use /tmp, I'd use /Users/luke (assuming that "luke" were your user directory on the Mac).
 
R Luke
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks again - your swift and most helpful reply made all the difference!  
 
You got style baby! More than this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic