Skip to content

Commit f0cd3e2

Browse files
authored
chore: make docs copyright year automatic (#160)
* chore: update CI version in docs * chore: use dynamic date in footer * cleanup * update license * update year * replace year with present in license file
1 parent 458204d commit f0cd3e2

File tree

5 files changed

+12
-2
lines changed

5 files changed

+12
-2
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ composer.lock
77
.DS_Store
88
.idea/
99
.vscode/
10+
docs/assets/__pycache__/

LICENSE

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
The MIT License (MIT)
22

33
Copyright (c) 2021 Lonnie Ezell
4+
Copyright (c) 2021-present CodeIgniter Foundation
45

56
Permission is hereby granted, free of charge, to any person obtaining a copy
67
of this software and associated documentation files (the "Software"), to deal

docs/assets/hooks.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
from datetime import datetime
2+
3+
def on_config(config, **kwargs):
4+
config.copyright = config.copyright.format(year=datetime.now().year)
5+
return config

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ service('settings')->forget('App.siteName');
3030
### Requirements
3131

3232
![PHP](https://img.shields.io/badge/PHP-%5E8.2-red)
33-
![CodeIgniter](https://img.shields.io/badge/CodeIgniter-%5E4.2.3-red)
33+
![CodeIgniter](https://img.shields.io/badge/CodeIgniter-%5E4.3-red)
3434

3535
### Acknowledgements
3636

mkdocs.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,10 @@ extra:
5353
site_url: https://settings.codeigniter.com/
5454
repo_url: https://github.com/codeigniter4/settings
5555
edit_uri: edit/develop/docs/
56-
copyright: Copyright © 2025 CodeIgniter Foundation.
56+
copyright: Copyright © 2021-{year} CodeIgniter Foundation.
57+
58+
hooks:
59+
- docs/assets/hooks.py
5760

5861
markdown_extensions:
5962
- admonition

0 commit comments

Comments
 (0)