Skip to content
Permalink
Browse files

Added introduction to contributing and updated readme

  • Loading branch information...
TotallyNotElite committed Nov 16, 2018
1 parent ec87635 commit 651d627e488ffc5678d8630943b32327a5d10d04
Showing with 58 additions and 30 deletions.
  1. +13 −26 CONTRIBUTING.md
  2. +8 −4 README.md
  3. +37 −0 code-style.md
39 CONTRIBUTING.md 100755 → 100644
@@ -1,35 +1,22 @@
# NullWorks code style (Work in progress)
## Contributing to Cathook or other Nullworks Projects

## C/C++
### Prerequisites

### General
- A working up-to-date cathook installation
- C++ knowledge
- Git knowledge
- Ability to ask for help (Feel free to create empty pull-request or PM a maintainer in [Telegram](https://t.me/nullifiedcat))

- Code must be formatted with `clang-format`, the `.clang-format` settings file is provided within this repo.
- `using namespace` is strictly forbidden.
- [Hungarian notation](https://en.wikipedia.org/wiki/Hungarian_notation) is forbidden.
### Pull requests and Branches

### File names
In order to send code back to the official cathook repository, you must first create a copy of cathook on your github account ([fork](https://help.github.com/articles/creating-a-pull-request-from-a-fork/)) and then [create a pull request](https://help.github.com/articles/creating-a-pull-request-from-a-fork/) back to cathook.

`PascalCase`.
All cathook developement is usually performed on the `testing` branch. Please make sure to submit your pull request to that branch.

### Header files
### Code-Style

Header files must have extension of `.hpp` and be guarded with `#pragma once` in the beginning.
The nullworks code-style can be found in `code-style.md`.

### Variable names
### Building

- Variable names must be `lower_snake_case`, member variable names **must not** be prefixed by `m_` or any other prefixes.
- Constants must be in `UPPER_SNAKE_CASE` and use `constexpr`, not `#define`. For example: `constexpr int MAX = 100;`.

### Namespace names

Namespace names follow the same rules as *Variable names*.

### Function names

Function/method names must be in `lowerCamelCase`.

### Class names

- Class names must be in `PascalCase`.
- Struct names must be in `lower_snake_case`.
Cathook has already created the directory `build` where cmake files are located. By default, you can build cathook by running `cmake .. && make -j$(grep -c '^processor' /proc/cpuinfo)` in the `build` directory. You can then test your changes by using one of the attach scripts at your disposal.
@@ -7,14 +7,18 @@

## Risk of VAC detection

The software Might be VAC detected. Only use it on accounts you won't regret getting VAC banned.
The software could be detected by VAC in the future. Only use it on accounts you won't regret getting VAC banned.

## Community
You can chat with other cathook users in [my official telegram group](https://t.me/nullifiedcat).
You can chat with other cathook users in [our official telegram group](https://t.me/nullifiedcat).

This comment has been minimized.

Copy link
@BenCat07

BenCat07 Nov 17, 2018

Collaborator

USSR ANTHEM PLAYS


## Important
## Reporting Issues

Right now cathook isn't in its greatest state, a lot of things may not work/crash the game, please open issues on github using [this page](https://github.com/nullworks/cathook/issues).
If some things doesn't work as expected, please open issues on GitHub using [this page](https://github.com/nullworks/cathook/issues).

## Contributing

Do you want to submit code to cathook? Please read `CONTRIBUTING.md` for a short introduction.

## Overview

@@ -0,0 +1,37 @@
# NullWorks code style (Work in progress)

## C/C++

### General

- Code must be formatted with `clang-format`, the `.clang-format` settings file is provided within this repo.
- `using namespace` is strictly forbidden.
- [Hungarian notation](https://en.wikipedia.org/wiki/Hungarian_notation) is forbidden.
- Comments should be above the relevant code.
- Use [modern c++](http://www.modernescpp.com/index.php/what-is-modern-c). (Usage of `make_unique` instead `new`, etc)

### File names

`PascalCase`.

### Header files

Header files must have extension of `.hpp` and be guarded with `#pragma once` in the beginning.

### Variable names

- Variable names must be `lower_snake_case`, member variable names **must not** be prefixed by `m_` or any other prefixes.
- Constants must be in `UPPER_SNAKE_CASE` and use `constexpr`, not `#define`. For example: `constexpr int MAX = 100;`.

### Namespace names

Namespace names follow the same rules as *Variable names*.

### Function names

Function/method names must be in `lowerCamelCase`.

### Class names

- Class names must be in `PascalCase`.
- Struct names must be in `lower_snake_case`.

0 comments on commit 651d627

Please sign in to comment.
You can’t perform that action at this time.