Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/w-mai/zongheng
https://github.com/w-mai/zongheng
Last synced: 26 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/w-mai/zongheng
- Owner: W-Mai
- Created: 2022-10-22T17:16:04.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-10-22T17:27:32.000Z (about 1 year ago)
- Last Synced: 2023-10-22T18:35:52.081Z (about 1 year ago)
- Language: C++
- Size: 78.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 纵横
ZongHeng is opposite theories of vertical and horizontal alliance of states with the state of Qin as pivot in Chinese
history.# General Usage
[![asciicast](https://asciinema.org/a/4hVNy8g5x5BBMQtjvNM27koqs.svg)](https://asciinema.org/a/4hVNy8g5x5BBMQtjvNM27koqs)
```c++
#include "Qin.h"
#includeusing namespace std;
int main() {
auto hello_str = std::string("Hello ");
auto hello = Qin::make(hello_str);
auto name = Qin::make();
auto mark = Qin::make(" !");
// 联合`变量`
auto sentence = hello + name + mark;sentence->getter([](const string& s) {
return s + " 🤤";
});auto name_tmp = std::string("World");
do {
// 一呼百应
*name = name_tmp;
cout << sentence->get() << endl;
} while (cin >> name_tmp);return 0;
}```
# Run Example
```shell
mkdir -p build && cd build
cmake .. && make -j
./example
```# Run Test
```shell
mkdir -p build && cd build
cmake .. && make -j
ctest
```# TODO
- [ ] Support more complex chain
- [ ] Support condition chain
- [ ] ...# Commit Information
| means | emoji |
|----------|-------|
| feature | ❤️ |
| fix | 🤡 |
| format | 🧾 |
| refactor | ⚙️ |
| update | 🆕 |
| WIP | ⌛️ |