Skip to content
Merged
Show file tree
Hide file tree
Changes from 250 commits
Commits
Show all changes
339 commits
Select commit Hold shift + click to select a range
f95f6ee
More fixes towards it working, need to do the final copy operations.
SharafMohamed Mar 5, 2025
3b1dafc
Remove UTF-8 case as its handled incorrectly.
SharafMohamed Mar 5, 2025
250f173
Update the way registers work; Fix simulation.
SharafMohamed Mar 6, 2025
db7bc11
Update reg handler test case.
SharafMohamed Mar 6, 2025
0b397e2
Explicit specialization of byte case.
SharafMohamed Mar 6, 2025
6716473
Figured out why repetition is failing to tag correctly.
SharafMohamed Mar 8, 2025
11cb2a7
Switch to unordered map.
SharafMohamed Mar 10, 2025
3e3d27a
Add test case for CLP schema.
SharafMohamed Mar 10, 2025
3638985
Merge branch 'add-register-operations' into determinization
SharafMohamed Mar 10, 2025
348a634
Update to handle merge.
SharafMohamed Mar 10, 2025
14aac7f
Merge branch 'main' into determinization
SharafMohamed Mar 10, 2025
f5bcce8
Rename determization to determinization.
SharafMohamed Mar 10, 2025
3c8c208
Run linter.
SharafMohamed Mar 10, 2025
be19363
Add unit-test for integer NFA. Currently, fails.
SharafMohamed Mar 12, 2025
dfc66de
Fix bug for 0 repetition case.
SharafMohamed Mar 13, 2025
ce88dc1
Fix logical error in if check for config mapping during determinizati…
SharafMohamed Mar 13, 2025
adefd0b
Add test case for ambiguous lexing rules; Disambiguate lexing rules i…
SharafMohamed Mar 14, 2025
b42fae9
Fix repeated reg ops for same register.
SharafMohamed Mar 16, 2025
7067112
Add return type of set_reg_id.
SharafMohamed Mar 28, 2025
1429996
Add helper function to reduce repetitive code in DFA unit tests.
SharafMohamed Mar 28, 2025
c7b8baf
Merge branch 'main' into determinization
SharafMohamed Mar 28, 2025
282b552
Add TODO.
SharafMohamed Mar 28, 2025
5e06805
Remove usage of [] for files in this PR; Add [[nodiscard]] for files …
SharafMohamed Mar 28, 2025
97c1088
Linter.
SharafMohamed Mar 28, 2025
5eba1f3
Fix docstring.
SharafMohamed Mar 28, 2025
16fd3a5
Merge branch 'main' into determinization
SharafMohamed Mar 28, 2025
34e70b8
Improve docstrings in Lexer.hpp; Update variable name for specificity…
SharafMohamed Mar 29, 2025
81e46db
Add Lexer docstring.
SharafMohamed Mar 29, 2025
9937d44
Update NfaState docstrings.
SharafMohamed Mar 29, 2025
db2951b
Improve docstrings in Dfa.hpp.
SharafMohamed Mar 29, 2025
7d13265
Update docstrings in DeterminizationConfiguration; Also, move update_…
SharafMohamed Mar 29, 2025
1b4c21b
Lint.
SharafMohamed Mar 29, 2025
836f587
Merge branch 'determinization' into scan-pair
SharafMohamed Mar 29, 2025
240a379
Remove leftover HEAD from previous commit.
SharafMohamed Mar 29, 2025
58b7a98
Merge branch 'scan-pair' into simulation
SharafMohamed Mar 29, 2025
5c86d3a
Fix bugs from CLP.
SharafMohamed Mar 29, 2025
928589c
Add back CODEOWNERS.
SharafMohamed Mar 31, 2025
c7cd662
Set up NFA to handle single-valued tags.
SharafMohamed Apr 2, 2025
c7523e8
Merge branch 'main' into single-valued-nfa
SharafMohamed Apr 2, 2025
a1548c4
Merge branch 'main' into single-valued-nfa
SharafMohamed Apr 7, 2025
653f997
Change add_delimiters to set_delimiters; Update docstring.
SharafMohamed Apr 9, 2025
4b8d0b9
Move TODO to git issue.
SharafMohamed Apr 9, 2025
66e02d2
Remove accidental q character.
SharafMohamed Apr 9, 2025
1225886
Forward multi_valued argument to tag creation functions.
SharafMohamed Apr 9, 2025
247d6b6
Finish forwarding descendaent_of_repetition to tag creation functions…
SharafMohamed Apr 9, 2025
61bc7ef
Add unit-test for multi-valued tag; Finish handling multi-valued tags…
SharafMohamed Apr 9, 2025
212cd5a
Add another unit-test for capture repetition regex.
SharafMohamed Apr 9, 2025
447491f
Update yscope-dev-utils.
SharafMohamed Apr 14, 2025
aa6e3e6
Revert yscope-dev-utils to mains commit.
SharafMohamed Apr 14, 2025
d400ad3
Update lexer docstring.
SharafMohamed Apr 21, 2025
b341266
Update add_rule docstring.
SharafMohamed Apr 21, 2025
2551bba
Update lexer docstring.
SharafMohamed Apr 21, 2025
3ca636d
Switched to tag_id_to_X_reg_id.
SharafMohamed Apr 21, 2025
457773c
Update initialize_register docstring.
SharafMohamed Apr 21, 2025
1600097
Update src/log_surgeon/finite_automata/DeterminizationConfiguration.hpp
SharafMohamed Apr 21, 2025
b94b6db
Update src/log_surgeon/finite_automata/Dfa.hpp
SharafMohamed Apr 21, 2025
643fa29
Update src/log_surgeon/Lexer.hpp
SharafMohamed Apr 21, 2025
5532506
Update m_tag_id_to_final_reg_id everywhere.
SharafMohamed Apr 21, 2025
d20afc6
Update src/log_surgeon/finite_automata/DeterminizationConfiguration.hpp
SharafMohamed Apr 21, 2025
f9c9443
Improve DeterminizationConfiguration docstring.
SharafMohamed Apr 22, 2025
78f2ce7
Add docstring for functions in DeterminizationConfiguration.
SharafMohamed Apr 22, 2025
4daa7be
Rename get_rule to get_highest_priority_rule.
SharafMohamed Apr 22, 2025
d5fdd43
Avoid duplicating tag to reg map.
SharafMohamed Apr 22, 2025
558056e
Improve DFA docstring.
SharafMohamed Apr 23, 2025
c2fae19
Merge branch 'determinization' into scan-pair
SharafMohamed Apr 28, 2025
4ebc72b
Merge branch 'single-valued-nfa' into scan-pair
SharafMohamed Apr 28, 2025
8431510
Remove unused param from docstring.
SharafMohamed Apr 28, 2025
f3413f2
Merge branch 'main' into scan-pair
SharafMohamed Apr 28, 2025
726e9b5
Merge branch 'main' into scan-pair
SharafMohamed May 1, 2025
c261077
Merge branch 'scan-pair' into simulation
SharafMohamed May 1, 2025
674b7ba
Merge branch 'main' into simulation
SharafMohamed May 11, 2025
12e1908
Clean up DFA tests.
SharafMohamed May 12, 2025
d9d6e71
Fix docstring.
SharafMohamed May 12, 2025
d8ac124
Use LogParser instead of creating a lexer that behaves exactly like L…
SharafMohamed May 12, 2025
a7757ab
Move regex AST tests into test-regex-ast.
SharafMohamed May 13, 2025
b593717
Copied future test cases.
SharafMohamed May 13, 2025
612a7a3
Rename test-lexer to test-parser.
SharafMohamed May 13, 2025
10a7ec0
Remove failing tests.
SharafMohamed May 13, 2025
5aa1a06
Fix backtracking.
SharafMohamed May 13, 2025
5e958d0
Remove integer test.
SharafMohamed May 13, 2025
0cc35b6
Remove doxygen stuff.
SharafMohamed May 13, 2025
728310d
Merge branch 'simulation' into backtrack
SharafMohamed May 13, 2025
9caa3c5
Fix integer bug.
SharafMohamed May 13, 2025
3bfca1a
Rename test.
SharafMohamed May 13, 2025
bfae2c1
Merge branch 'simulation' into backtrack
SharafMohamed May 13, 2025
d51945b
Merge branch 'backtrack' into integer-bugfix
SharafMohamed May 13, 2025
275d6d3
Add schema test.
SharafMohamed May 13, 2025
e95cb97
Merge branch 'simulation' into backtrack
SharafMohamed May 13, 2025
65bda1c
Retag to LogParser.
SharafMohamed May 13, 2025
19ab8e8
Merge branch 'backtrack' into integer-bugfix
SharafMohamed May 13, 2025
9183017
Add missing files.
SharafMohamed May 14, 2025
69db303
Update doxygen files.
SharafMohamed May 21, 2025
ab4c6e5
Update doxygen files.
SharafMohamed May 21, 2025
b2e6fa1
Update doxygen files again again.
SharafMohamed May 21, 2025
540ea9b
Edit mainpage
SharafMohamed May 21, 2025
c0ce8ef
Seperate changes for PR.
SharafMohamed May 31, 2025
5e2cc00
Remove unneeded changes.
SharafMohamed May 31, 2025
1652c68
Remove unneeded changes.
SharafMohamed May 31, 2025
81f096a
Remove TODO.
SharafMohamed Jun 2, 2025
c9aa27a
Fix typo.
SharafMohamed Jun 2, 2025
f90a3a1
Correct function name.
SharafMohamed Jun 2, 2025
77cf7b2
Lint.
SharafMohamed Jun 2, 2025
dccf59f
Update tests.
SharafMohamed Jun 2, 2025
407ac20
Add tagged simulation.
SharafMohamed Jun 2, 2025
02ae78e
Update error handling for add_variable and add_delimiters; Add unit-t…
SharafMohamed Jun 4, 2025
4a8204e
Add inverse_priority bounds checking; Add more tests for bounds check…
SharafMohamed Jun 4, 2025
6f08e99
Merge branch 'simulation' into backtrack
SharafMohamed Jun 4, 2025
2933ce8
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 4, 2025
ffc5d74
Update docstring in src/log_surgeon/Token.hpp.
SharafMohamed Jun 4, 2025
07cbe26
Rename add_context_to_logtype to append_context_to_logtype.
SharafMohamed Jun 4, 2025
b4f569b
Update test to be used in buffer-parser instead of log-parser (soon t…
SharafMohamed Jun 4, 2025
4ffe762
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 4, 2025
e148f04
Docstring update 1.
SharafMohamed Jun 5, 2025
5a74322
Update docstring for buffer parser without capture groups test.
SharafMohamed Jun 5, 2025
7540c1b
Add docstring for all buffer parser test cases.
SharafMohamed Jun 5, 2025
77c2a48
Add buffer parser test to cmake.
SharafMohamed Jun 5, 2025
5663058
Merge branch 'simulation-support-captures' of https://github.com/Shar…
SharafMohamed Jun 5, 2025
2e301a5
Compilation fix for previous function name change.
SharafMohamed Jun 5, 2025
9a047e9
Lint.
SharafMohamed Jun 5, 2025
ab06f0c
Merge branch 'simulation-support-captures' into simulation-buffer-tests
SharafMohamed Jun 5, 2025
97652e4
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 5, 2025
a17e041
Remove conflict marker.
SharafMohamed Jun 5, 2025
0b997f9
Merge branch 'simulation' into backtrack
SharafMohamed Jun 5, 2025
2a65fb2
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 5, 2025
fda91ec
Move test into correct file.
SharafMohamed Jun 5, 2025
1574882
Add docstring for new test cases in buffer parser.
SharafMohamed Jun 5, 2025
0ddb732
Merge branch 'simulation' into backtrack
SharafMohamed Jun 5, 2025
20ba064
Fix test name and tag.
SharafMohamed Jun 5, 2025
3bc5313
Add docstring for new test case.
SharafMohamed Jun 5, 2025
e77cb93
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 5, 2025
9814550
Add last docstring for buffer tests.
SharafMohamed Jun 5, 2025
396a549
Delete new unit tests.
SharafMohamed Jun 5, 2025
b34399c
Improve naming consitency in test-buffer-parser.cpp.
SharafMohamed Jun 5, 2025
559b337
Merge branch 'simulation-support-captures' into simulation-buffer-tests
SharafMohamed Jun 5, 2025
aecd1a6
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 5, 2025
7fae265
Improve naming consitency in test-buffer-parser.cpp.
SharafMohamed Jun 5, 2025
135212f
Merge branch 'simulation' into backtrack
SharafMohamed Jun 5, 2025
fef817b
Delete duplicate unit test file.
SharafMohamed Jun 5, 2025
1b4373f
Delete duplicate unit test file.
SharafMohamed Jun 5, 2025
6254ef1
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 5, 2025
bd9a1d3
Moved TODO to git issue.
SharafMohamed Jun 5, 2025
7a6c9e5
Merge branch 'simulation-support-captures' into simulation-buffer-tests
SharafMohamed Jun 5, 2025
4ecafda
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 5, 2025
e0e0821
Lint.
SharafMohamed Jun 5, 2025
8673fe8
Merge remote-tracking branch 'upstream/main' into pr-117
davidlion Jun 9, 2025
b7430ae
Apply updated clang-format changes.
davidlion Jun 9, 2025
af06e46
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 11, 2025
d7ae722
Merge branch 'simulation' into backtrack
SharafMohamed Jun 11, 2025
5871fcc
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 11, 2025
bf6eb63
Update tests/test-buffer-parser.cpp
SharafMohamed Jun 16, 2025
15c60a7
Remove repeated U for raw strings. Delete unused test file.
SharafMohamed Jun 16, 2025
bdf3928
Remove TODOs moved to issue.
SharafMohamed Jun 16, 2025
dac9b0c
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 16, 2025
2aee692
Update name of new tests cases.
SharafMohamed Jun 16, 2025
94014a8
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 16, 2025
b3310cd
Run linter.
SharafMohamed Jun 16, 2025
4c23525
Merge branch 'simulation' into backtrack
SharafMohamed Jun 16, 2025
36fb7c2
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 16, 2025
022b6d0
Move TODOs into git issues.
SharafMohamed Jun 17, 2025
157591f
Update test case names.
SharafMohamed Jun 17, 2025
ba0c78f
Remove return type from process_char.
SharafMohamed Jun 17, 2025
ea14ae6
Merge branch 'simulation' into backtrack
SharafMohamed Jun 17, 2025
49a5c10
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 17, 2025
b290d94
Fix test case names in schema tests.
SharafMohamed Jun 17, 2025
da74d6c
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 17, 2025
f1e0704
Merge branch 'simulation' into backtrack
SharafMohamed Jun 17, 2025
31cd2db
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 17, 2025
fa53a0c
Update tests/test-schema.cpp
SharafMohamed Jun 17, 2025
5c3df7c
Update tests/test-schema.cpp
SharafMohamed Jun 17, 2025
3b3f226
Update test-buffer-parser test names.
SharafMohamed Jun 17, 2025
7b9af31
Merge branch 'simulation-buffer-tests' into simulation
SharafMohamed Jun 17, 2025
e239c90
Merge branch 'simulation' into backtrack
SharafMohamed Jun 17, 2025
abb5150
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 17, 2025
251c474
Merge branch 'main' into simulation
SharafMohamed Jun 17, 2025
54c6bc6
Update unit-test names.
SharafMohamed Jun 17, 2025
b99d5e6
Update src/log_surgeon/finite_automata/Dfa.hpp
SharafMohamed Jun 18, 2025
fd8443e
Update src/log_surgeon/finite_automata/Dfa.hpp
SharafMohamed Jun 18, 2025
83993ea
Update tests/test-buffer-parser.cpp
SharafMohamed Jun 18, 2025
38be2bc
Remove doxygen files.
SharafMohamed Jun 18, 2025
74ff1c6
Rename set to set_curr_state.
SharafMohamed Jun 18, 2025
0253e31
Lint.
SharafMohamed Jun 18, 2025
f047b65
Use process_state (renamed to process_reg_ops) in process_char.
SharafMohamed Jun 18, 2025
35e30bb
Propogate previous commit changes
SharafMohamed Jun 18, 2025
14782af
Update release_reg_handler.
SharafMohamed Jun 18, 2025
eca733b
Update docstring.
SharafMohamed Jun 18, 2025
839a621
Consolidate state information b/w Dfa and Lexer into Lexer.
SharafMohamed Jun 18, 2025
7736f80
Remove TODO.
SharafMohamed Jun 18, 2025
0dfaed9
Update docstrings; Remove process_char from Dfa header.
SharafMohamed Jun 18, 2025
e4e3747
Merge branch 'simulation' into backtrack
SharafMohamed Jun 18, 2025
4a8aa6e
Merge branch 'main' into backtrack
SharafMohamed Jun 18, 2025
ce3aa99
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 18, 2025
1a8a4c4
Add docs back in.
SharafMohamed Jun 18, 2025
575acd5
Remove TODO.
SharafMohamed Jun 19, 2025
d42baeb
Remove optional from member var name.
SharafMohamed Jun 19, 2025
0893ac1
Fix delimiter docstring.
SharafMohamed Jun 19, 2025
2290494
Update test name.
SharafMohamed Jun 19, 2025
d6e7a18
Merge branch 'backtrack' into integer-bugfix
SharafMohamed Jun 19, 2025
56a6ae7
Update test name.
SharafMohamed Jun 19, 2025
1eebf2f
Remove redundant lint; Remove TODO.
SharafMohamed Jun 19, 2025
84dd2c7
Merge branch 'main' into integer-bugfix
SharafMohamed Jun 19, 2025
5995eff
Merge branch 'integer-bugfix' into doxygen
SharafMohamed Jun 19, 2025
c1f9981
Update tests/test-buffer-parser.cpp
SharafMohamed Jun 20, 2025
c42340d
Merge branch 'integer-bugfix' into doxygen
SharafMohamed Jun 20, 2025
abaee83
change log_parser to buffer_parser in docs to make sure everything is…
SharafMohamed Jun 20, 2025
e2b3f5f
Update README.
SharafMohamed Jun 20, 2025
ac3fbd0
Remove the feature to toggle dark mode since its not really working.
SharafMohamed Jun 23, 2025
8df95de
Remove ) typo.
SharafMohamed Jun 23, 2025
059a1c9
Add doxygen.yaml to workflows and taskfiles.
SharafMohamed Jun 24, 2025
61f54ec
Remove : from utils to run relative checksum; Add reference to utils;…
SharafMohamed Jun 25, 2025
cf38854
Merge branch 'main' into doxygen
SharafMohamed Jun 25, 2025
ccfa116
Merge branch 'doxygen-taskfile' into doxygen
SharafMohamed Jun 25, 2025
d37dd53
Run doxygen from the correct directory; Update output directory to be…
SharafMohamed Jun 25, 2025
630c2d0
Lint yaml.
SharafMohamed Jun 25, 2025
e973162
Use checkout and artifact v4 instead of v3.
SharafMohamed Jun 25, 2025
c0a3d56
Merge branch 'main' into doxygen
SharafMohamed Jun 25, 2025
31a24d3
Install doxygen in workflow.
SharafMohamed Jun 25, 2025
b8c1162
Update README.
SharafMohamed Jun 25, 2025
a277a1f
Rename tasks and add doxygen dependency to taskfile.
davidlion Jun 25, 2025
24e93d6
Merge commit 'refs/pull/133/head' of https://github.com/y-scope/log-s…
davidlion Jun 25, 2025
c683921
Update tasks in readme.
davidlion Jun 25, 2025
876e326
README update.
davidlion Jun 25, 2025
e682ebd
Fix typos.
davidlion Jun 26, 2025
a9f2bc9
Minimize Doxyfile entries by removing defaults.
davidlion Jun 26, 2025
7308c6b
Switch to markdown headers; Make test cases valid c++ names.
davidlion Jun 26, 2025
955b159
Refactor test names.
davidlion Jul 2, 2025
a6c1890
Address offline discussion comments.
davidlion Jul 8, 2025
dd0fa3d
Added missing defgroups back.
davidlion Jul 8, 2025
4902fb8
Reflow text.
davidlion Jul 8, 2025
d6b59e4
Attempt at renaming unit tests to be more consistent.
davidlion Jul 8, 2025
bee0794
More test naming tweaks.
davidlion Jul 8, 2025
bd4328a
Pluralize capture groups in multi_valued_capture_1 test as there are …
SharafMohamed Jul 8, 2025
157f5f1
Update tests/test-schema.cpp
SharafMohamed Jul 9, 2025
4fb1f61
Switch doxyfile comments to sentence case.
SharafMohamed Jul 9, 2025
d9e6be3
Update docs/doxygen/Doxyfile
SharafMohamed Jul 9, 2025
820b5fe
Update docs/doxygen/mainpage.dox
SharafMohamed Jul 9, 2025
a941361
Update taskfiles/docs.yaml
SharafMohamed Jul 9, 2025
0d20c9b
Update taskfiles/docs.yaml
SharafMohamed Jul 9, 2025
419f50f
Update taskfiles/docs.yaml
SharafMohamed Jul 9, 2025
1d611c4
Switch -c -1 back to -c-1
SharafMohamed Jul 9, 2025
a92f252
Update README.md
SharafMohamed Jul 9, 2025
a4ba9d1
Update README.md
SharafMohamed Jul 9, 2025
a064150
Update README.md
SharafMohamed Jul 11, 2025
d223cd1
Add run once to http-server.
SharafMohamed Jul 11, 2025
b556496
Deduplicate doxygen filename.
SharafMohamed Jul 11, 2025
e01f97a
Add quotations to task variable
SharafMohamed Jul 11, 2025
76dd1b2
alphabetize.
SharafMohamed Jul 11, 2025
cc148e8
Add docs.yaml to lint task.
SharafMohamed Jul 11, 2025
c69dd60
Switch to sentence case for defgroup; Update some documentation for c…
SharafMohamed Jul 11, 2025
5049e39
Lint.
SharafMohamed Jul 11, 2025
0894856
Pin commits.
SharafMohamed Jul 11, 2025
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
46 changes: 46 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: "docs"

on:
pull_request:
push:
schedule:
# Run daily at 00:15 UTC (the 15 is to avoid periods of high load)
- cron: "15 0 * * *"
workflow_dispatch:

concurrency:
group: "${{github.workflow}}-${{github.ref}}"

# Cancel in-progress jobs for efficiency
cancel-in-progress: true

jobs:
build:
name: "Build docs site"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
with:
lfs: "true"
submodules: "recursive"

- name: "Install task"
shell: "bash"
run: "npm install -g @go-task/cli"

- name: "Build docs"
shell: "bash"
run: "task docs:site"

# Upload the built docs site if we need to debug any issues
- if: >-
contains(fromJSON('["push", "workflow_dispatch"]'), github.event_name)
&& ('refs/heads/main' == github.ref || startsWith(github.ref, 'refs/tags/v'))
uses: "actions/upload-artifact@v4"
with:
name: "docs-html"
path: "build/docs/html"
if-no-files-found: "error"

# Retain the artifact for a week
retention-days: 7
25 changes: 23 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,34 @@ To build the debug version:
task build:debug
```

## Documentation and examples
## Examples

[examples](examples) contains programs demonstrating usage of the library.
See [examples/README.md](examples/README.md) for information on building and running the examples.

## Documentation

* [docs](docs) contains more detailed documentation including:
* The [schema specification](docs/schema.md), which describes the syntax for
writing your own schema
* `log-surgeon`'s [design objectives](docs/design-objectives.md)
* [examples](examples) contains programs demonstrating usage of the library.

### Documentation site

You can generate a documentation site that is useful for exploring functionality and test coverage.
In particular, this documents all unit-tests, with additional detail for API-level tests.

#### Commands

To generate and view the files:

* Run `task docs:site`.
* Open `build/docs/html/index.html` in your preferred browser.

To host the site locally and view it:

* Run `task docs:serve`.
* Open the URL and port output from the `serve` task in your preferred browser.

## Testing

Expand Down
25 changes: 25 additions & 0 deletions docs/doxygen/Doxyfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Project Information
PROJECT_BRIEF = "Test coverage and internal documentation"
PROJECT_NAME = "Log Surgeon"
OUTPUT_DIRECTORY = build/docs/

# Input
INPUT = \
docs/doxygen/mainpage.dox \
tests/
RECURSIVE = YES

# Source Code Parsing
EXTRACT_ALL = YES
EXTRACT_PRIVATE = YES
EXTRACT_STATIC = YES
MACRO_EXPANSION = YES
PREDEFINED = "TEST_CASE(x,y)=void x()"

# Output
GENERATE_LATEX = NO
HTML_DYNAMIC_SECTIONS = YES
TIMESTAMP = YES

# Misc
WARN_AS_ERROR = YES
20 changes: 20 additions & 0 deletions docs/doxygen/mainpage.dox
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/** @mainpage
*
* # Use case examples of schema rules and parsing results:
*
* - @ref test_buffer_parser_no_capture "Use basic log parser"
* - @ref test_buffer_parser_capture "Use captures"
* - @ref test_buffer_parser_default_schema "Default CLP schema"
* - @ref test_buffer_parser_delimited_variables "Backtracking on delimited variables"
* - @ref test_buffer_parser_newline_vars "Identifying variables at the start of a line"
*
* # Unit-tests:
*
* - @ref unit_tests_capture "Capture"
* - @ref unit_tests_dfa "DFA"
* - @ref unit_tests_nfa "NFA"
* - @ref unit_tests_prefix_tree "Prefix tree"
* - @ref unit_tests_regex_ast "Regex AST"
* - @ref unit_tests_register_handler "Register handler"
* - @ref unit_tests_schema "Schema"
*/
1 change: 1 addition & 0 deletions taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ shopt: ["globstar"]
includes:
build: "taskfiles/build.yaml"
deps: "taskfiles/deps.yaml"
docs: "taskfiles/docs.yaml"
lint: "taskfiles/lint.yaml"
test: "taskfiles/test.yaml"

Expand Down
98 changes: 98 additions & 0 deletions taskfiles/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
version: "3"

includes:
utils:
internal: true
taskfile: "../tools/yscope-dev-utils/exports/taskfiles/utils/utils.yaml"

vars:
# General paths
G_DOCS_BUILD_DIR: "{{.G_BUILD_DIR}}/docs"
G_DOCS_HTML_DIR: "{{.G_DOCS_BUILD_DIR}}/html"
G_DOCS_VENV_DIR: "{{.G_DOCS_BUILD_DIR}}/docs-venv"
G_NODE_DEPS_DIR: "{{.G_DOCS_BUILD_DIR}}/docs-node"

# Doxygen paths
G_DOXYFILE_PATH: "{{.ROOT_DIR}}/docs/doxygen/Doxyfile"
G_DOXYGEN_CMD: "{{.G_DOCS_VENV_DIR}}/bin/doxygen"

tasks:
clean:
cmds:
- "rm -rf '{{.G_DOCS_BUILD_DIR}}'"

serve:
deps:
- "http-server"
- "site"
cmds:
- "npm --prefix '{{.G_NODE_DEPS_DIR}}' exec -- http-server '{{.G_DOCS_HTML_DIR}}' -c-1"

site:
vars:
CHECKSUM_FILE: "{{.G_BUILD_DIR}}/{{.TASK | replace \":\" \"#\"}}.md5"
OUTPUT_DIR: "{{.G_DOCS_HTML_DIR}}"
sources:
- "{{.G_DOXYFILE_PATH}}"
- "{{.ROOT_DIR}}/docs/**/*"
- "{{.ROOT_DIR}}/src/**/*"
- "{{.ROOT_DIR}}/taskfile.yaml"
- "{{.ROOT_DIR}}/tests/**/*"
- "{{.TASKFILE}}"
generates: ["{{.CHECKSUM_FILE}}"]
deps:
- "venv"
- task: "utils:checksum:validate"
vars:
CHECKSUM_FILE: "{{.CHECKSUM_FILE}}"
INCLUDE_PATTERNS: ["{{.OUTPUT_DIR}}"]
cmds:
- |-
rm -rf "{{.G_DOCS_HTML_DIR}}"
cd "{{.ROOT_DIR}}"
{{.G_DOXYGEN_CMD}} "{{.G_DOXYFILE_PATH}}"
# This command must be last
- task: "utils:checksum:compute"
vars:
CHECKSUM_FILE: "{{.CHECKSUM_FILE}}"
INCLUDE_PATTERNS: ["{{.OUTPUT_DIR}}"]

http-server:
internal: true
vars:
CHECKSUM_FILE: "{{.G_BUILD_DIR}}/{{.TASK | replace \":\" \"#\"}}.md5"
OUTPUT_DIR: "{{.G_NODE_DEPS_DIR}}"
sources:
- "{{.ROOT_DIR}}/taskfile.yaml"
- "{{.TASKFILE}}"
generates: ["{{.CHECKSUM_FILE}}"]
deps:
- ":init"
- task: "utils:checksum:validate"
vars:
CHECKSUM_FILE: "{{.CHECKSUM_FILE}}"
INCLUDE_PATTERNS: ["{{.OUTPUT_DIR}}"]
cmds:
- "rm -rf '{{.OUTPUT_DIR}}'"
- "npm --prefix '{{.OUTPUT_DIR}}' install http-server"
# This command must be last
- task: "utils:checksum:compute"
vars:
CHECKSUM_FILE: "{{.CHECKSUM_FILE}}"
INCLUDE_PATTERNS: ["{{.OUTPUT_DIR}}"]

venv:
internal: true
run: "once"
deps:
- ":init"
cmds:
- "mkdir -p '{{.G_DOCS_VENV_DIR}}'"
- task: "utils:remote:download-and-extract-tar"
vars:
FILE_SHA256: "e5d6ae24d0bf3f0cdc4d8f146726b89ca323922f19441af99b1872d503665ad6"
INCLUDE_PATTERNS:
- "bin"
OUTPUT_DIR: "{{.G_DOCS_VENV_DIR}}"
TAR_FILE: "{{.G_DOCS_BUILD_DIR}}/doxygen-1.14.0.linux.bin.tar.gz"
URL: "https://www.doxygen.nl/files/doxygen-1.14.0.linux.bin.tar.gz"
Loading
Loading