Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Build C++

on:
push:
branches: [ "devops", "main" ]
pull_request:
branches: [ "main" ]

jobs:
build-and-test:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Install dependencies
run: |
sudo apt-get update
sudo apt-get install -y build-essential g++

- name: Compile C++ program
run: |
g++ -Wall -Wextra -std=c++11 main.cpp -o main

32 changes: 32 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Prerequisites
*.d

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# autovalidate
[![C++ CI](https://github.com/er02869/autovalidate/actions/workflows/actions.yml/badge.svg)](https://github.com/er02869/autovalidate/actions/workflows/actions.yml)

I like that app too!

This repo is compatible with the [cpp-container docker container](https://github.com/ChicoState/cpp-container).
# Autovalidate
Binary file added main
Binary file not shown.
10 changes: 9 additions & 1 deletion main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,16 @@ int main(){
cout << "What are you listening to?\n";
getline(cin,input);
transform(input.begin(), input.end(), input.begin(), [](unsigned char c){ return std::tolower(c); });
cout << VALIDATION[pick] << "! Let's listen to more\n";


if(input == "nothing" || input == ""){
cout << "Oh... okay. Bye!\n";
cout << "Testing for actions.yml agai\n";
return 0;
}

cout << VALIDATION[pick] << "! Let's listen to more\n";

do{
cout << "What's next?\n";
getline(cin,input);
Expand Down