My First Project (CLI Project)

Chelsea Roland
4 min readDec 5, 2020

After a week of being very nervous about my upcoming first project it’s time to get to work. Luckily, I’m provided with videos by multiple teachers to give me an idea of how I want my project to look/act.

I started brainstorming what I would like to create, as I was laying in my bed, I get the idea that I wanted to do something fun, in 2020 we need as many pick-me-ups as we can get! The next morning, I wake up and begin my morning routine which includes watching an astrologer on Tik Tok (she’s has great content.) It hits me, bingo! astrology! I start my plan on building a gem that gives you your daily horoscope.

First, I can start noting how I want everything to work. what are some attributes that I want my gem to have? what are some of the different options available to the user?

I take the first step in the process by thinking about different options that I can give the user. I know that I want people to have the option to view a list of signs. If someone is new to astrology, they might not know their sign.

I wanted my code to be easy to read and as neat as possible keeping that in mind as much as possible while my brain is throwing out ideas.

Next, I create my CLI file this will simplify my interface and directly interact with the user.

Now I can build this out which I know will look something like this:

CLI class

call — Welcomes the user and gives them options to choose from.

display info — Will call on the API

input — Uses if/eslf/else statements to understand what the user would like to see and return those values.

signs list — Display the list of all the signs with their date ranges so that the user can see where they or others fall in the zodiac, and then asks which sign they would like to view.

goodbye — When the user wants to exit the program they are met with an appropriate message when leaving.

I noticed that the API I chose has a bunch of different information aside from the original daily horoscope I was thinking of, this includes: lucky number, color for the day, mood, lucky time of the day, and compatibility.

Bonus! I definitely want to use all of this awesome information

Now, I create a description(horoscope) file and push this information into a new array so I can later pull the data out and also make it look attractive to the user.

I now go back into my creative process by asking myself some questions. How exactly do I want to interact with the user? How can I personalize their experience? I’m constantly making small changes to the app so it possesses the best user experience.

What would make the app easy to use for all? what if the user would like to view the history of what they were looking at?

What if they want to view several different signs?

What can I do to make it look nice and neat and easy to read?

of course, everyone has different preferences, but I tried to keep in mind what would be easiest and cleanest for each and every user. I tried putting myself in the user’s shoes and making comments on my own work. I instantly thought “I wish there was some space between these lines so that I could read easier.” That’s how we can make our projects be the best, by making it graceful for someone else or ourselves to come back and read, and most importantly for the user themselves.

I return to my CLI class and start building new methods to incorporate these ideas which include:

loop or exit — Asks the user if they would like to choose a different sign. Maybe the user is with a friend or significant other and would like to read the info for a different sign.

history — Asks the user if they would like to see the past history of the different horoscopes they have read.

display all history — A method to display said history.

Now, I am playing with my project, running through different signs because I’m having fun acting as the user. I am confident this has officially become what I wanted to originally create, something fun! Of course, when creating something new and writing code, we will have errors and points where we are stuck or confused. I think it’s very important to ask for help when needed and to look back at previous things you have learned or created.

Thankfully i have an amazing teacher who could help me get a deeper understanding of what I was doing and most importantly why. Why do we need good communication between our data? How can we read those errors and understand where and why they are happening? What is a way we can simplify our code or make it tidy?

At the end of the week, I am tired but proud. I have put a lot of work into my little gem but for me it has paid off. My project has more options and information than I even originally planned on in the beginning and that’s a great feeling when you can add more to something and making it greater than you ever imagined.

--

--