Skip to content

Commit 0630783

Browse files
committed
Update more to "travels"
1 parent bd90aae commit 0630783

File tree

6 files changed

+23
-23
lines changed

6 files changed

+23
-23
lines changed

CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,10 @@ include(${_project_options_SOURCE_DIR}/Index.cmake)
4949

5050
# Set the project name and language
5151
project(
52-
my_awesome_game
52+
travels
5353
VERSION 0.0.1
5454
DESCRIPTION ""
55-
HOMEPAGE_URL "https://github.com/lefticus/my_awesome_game"
55+
HOMEPAGE_URL "https://github.com/cpp-best-practices/travels"
5656
LANGUAGES CXX C)
5757

5858
set(GIT_SHA
@@ -161,11 +161,11 @@ if(MSVC)
161161
endif()
162162

163163
# set the startup project for the "play" button in MSVC
164-
set_property(DIRECTORY PROPERTY VS_STARTUP_PROJECT awesome_game)
164+
set_property(DIRECTORY PROPERTY VS_STARTUP_PROJECT travels)
165165

166166
# Add other targets that you want installed here, be default we just package the one executable
167167
# we know we want to ship
168-
package_project(TARGETS awesome_game)
168+
package_project(TARGETS travels)
169169

170170
# Experience shows that explicit package naming can help make it easier to sort
171171
# out potential ABI related issues before they start, while helping you

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# Travels
22

3-
[![ci](https://github.com/cpp-best-practices/travels/actions/workflows/ci.yml/badge.svg)](https://github.com/lefticus/my_awesome_game/actions/workflows/ci.yml)
4-
[![codecov](https://codecov.io/gh/cpp-best-practices/travels/branch/main/graph/badge.svg)](https://codecov.io/gh/lefticus/my_awesome_game)
5-
[![CodeQL](https://github.com/cpp-best-practices/travels/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/lefticus/my_awesome_game/actions/workflows/codeql-analysis.yml)
6-
[![Language grade: C++](https://img.shields.io/lgtm/grade/cpp/github/cpp-best-practices/travels)](https://lgtm.com/projects/g/lefticus/my_awesome_game/context:cpp)
3+
[![ci](https://github.com/cpp-best-practices/travels/actions/workflows/ci.yml/badge.svg)](https://github.com/cpp-best-practices/travels/actions/workflows/ci.yml)
4+
[![codecov](https://codecov.io/gh/cpp-best-practices/travels/branch/main/graph/badge.svg)](https://codecov.io/gh/cpp-best-practices/travels)
5+
[![CodeQL](https://github.com/cpp-best-practices/travels/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/cpp-best-practices/travels/actions/workflows/codeql-analysis.yml)
6+
[![Language grade: C++](https://img.shields.io/lgtm/grade/cpp/github/cpp-best-practices/travels)](https://lgtm.com/projects/g/cpp-best-practices/travels/context:cpp)
77

88
## About Travels
99

configured_files/config.hpp.in

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
#ifndef my_awesome_game_CONFIG_HPP
2-
#define my_awesome_game_CONFIG_HPP
1+
#ifndef travels_CONFIG_HPP
2+
#define travels_CONFIG_HPP
33

44
// this is a basic example of how a CMake configured file might look
55
// in this particular case, we are using it to set the version number of our executable
6-
namespace my_awesome_game::cmake {
6+
namespace travels::cmake {
77
static constexpr std::string_view project_name = "@PROJECT_NAME@";
88
static constexpr std::string_view project_version = "@PROJECT_VERSION@";
99
static constexpr std::string_view source_dir = "@CMAKE_SOURCE_DIR@";
@@ -12,6 +12,6 @@ static constexpr int project_version_minor { @PROJECT_VERSION_MINOR@ };
1212
static constexpr int project_version_patch { @PROJECT_VERSION_PATCH@ };
1313
static constexpr int project_version_tweak { @PROJECT_VERSION_TWEAK@ };
1414
static constexpr std::string_view git_sha = "@GIT_SHA@";
15-
}// namespace my_awesome_game::cmake
15+
}// namespace travels::cmake
1616

1717
#endif

src/CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ find_package(nlohmann_json CONFIG)
66

77
# Generic test that uses conan libs
88
add_executable(
9-
awesome_game
9+
travels
1010
main.cpp
1111
color.hpp
1212
size.hpp
@@ -27,7 +27,7 @@ add_executable(
2727
game_components.cpp)
2828

2929
target_link_libraries(
30-
awesome_game
30+
travels
3131
PRIVATE project_options
3232
project_warnings
3333
docopt::docopt
@@ -37,10 +37,10 @@ target_link_libraries(
3737
nlohmann_json::nlohmann_json)
3838

3939
target_link_system_libraries(
40-
awesome_game
40+
travels
4141
PRIVATE
4242
ftxui::screen
4343
ftxui::dom
4444
ftxui::component)
4545

46-
target_include_directories(awesome_game PRIVATE "${CMAKE_BINARY_DIR}/configured_files/include")
46+
target_include_directories(travels PRIVATE "${CMAKE_BINARY_DIR}/configured_files/include")

src/main.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
#include "size.hpp"
3131

3232
// This file will be generated automatically when you run the CMake
33-
// configuration step. It creates a namespace called `my_awesome_game`. You can modify
33+
// configuration step. It creates a namespace called `travels`. You can modify
3434
// the source template at `configured_files/config.hpp.in`.
3535
#include <internal_use_only/config.hpp>
3636

@@ -443,8 +443,8 @@ std::vector<std::filesystem::path> resource_search_directories()
443443
current_path = current_path.parent_path();
444444
}
445445

446-
results.emplace_back(my_awesome_game::cmake::source_dir);
447-
results.push_back(std::filesystem::path(my_awesome_game::cmake::source_dir) / "resources");
446+
results.emplace_back(travels::cmake::source_dir);
447+
results.push_back(std::filesystem::path(travels::cmake::source_dir) / "resources");
448448

449449
return results;
450450
}
@@ -470,8 +470,8 @@ int main(int argc, const char **argv)
470470
{ std::next(argv), std::next(argv, argc) },
471471
true,// show help if requested
472472
fmt::format("{} {}",
473-
my_awesome_game::cmake::project_name,
474-
my_awesome_game::cmake::project_version));// version string, acquired
473+
travels::cmake::project_name,
474+
travels::cmake::project_version));// version string, acquired
475475
// from config.hpp via CMake
476476

477477
// to start the lessons, comment out this line

test/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ target_link_libraries(catch_main PUBLIC Catch2::Catch2)
88
target_link_libraries(catch_main PRIVATE project_options)
99

1010
# Provide a simple smoke test to make sure that the CLI works and can display a --help message
11-
add_test(NAME cli.has_help COMMAND awesome_game --help)
11+
add_test(NAME cli.has_help COMMAND travels --help)
1212

1313
# Provide a test to verify that the version being reported from the application
1414
# matches the version given to CMake. This will be important once you package
1515
# your program. Real world shows that this is the kind of simple mistake that is easy
1616
# to make, but also easy to test for.
17-
add_test(NAME cli.version_matches COMMAND awesome_game --version)
17+
add_test(NAME cli.version_matches COMMAND travels --version)
1818
set_tests_properties(cli.version_matches PROPERTIES PASS_REGULAR_EXPRESSION "${PROJECT_VERSION}")
1919

2020

0 commit comments

Comments
 (0)