Skip to content

Commit

Permalink
chore: update license header (#3623)
Browse files Browse the repository at this point in the history
# Initial Problem
All files in our project have a different copyright header, which may or may not be updated when changes are done. This adds some clutter and unnecessary thinking to each PR.

# Solution attempts
The most beautiful solution would be to automatically update each file with creation-date and when it was last touched. However, this is not possible, because of some reasons.

## Creation date
We could go back into the git logs and check the first entry. This gets a bit confusing, when we rename/move files. In theory, it should work with `--follow`. However, I noticed, that often the suggested creation date is newer, than the actual one, following all PRs by hand.

## Modification date
For this one, we get definitely the correct year, however, by updating the headers to the actual year, we add an modification in this year. In the end, we would need to update all files to this year (Except those, that weren't touch outsider their initial creation year.)

# Options
In the end it boils down to 3 options with their ups and downs

## 🅰 `git_add_date` to `today` (current proposal)
This is an approach to get the most accurate numbers out.
Pros:
- Sophisticated
- We get a feeling, how old the code might be

Cons:
- The first year can be wrong (too recent) due to git-bugs
- Needs code for handling

## 🅱 `existing_date` to `today`
Similar to 🅰 but with the assumption, that we trust our old code more than the buggy git-log.

## 🅲 min(🅰, 🅱)
We could use the data provided in 🅰 and 🅱 and only use the `git_add_date` when it is smaller, than the indicated date. Still not perfect, but maybe a bit better. This option is probably not the best for keeping in the CI and pre-commit.

## 🅳 `2016` to `today`
Uses the full span.
Pros:
- Check is easy
- Every file looks the same

Cons:
- Header contains no additional information
- We are pre-dating all (c)s

# Other changes
- Acts -> ACTS, since we converged to that spelling
- http:// -> https:// in the license link
  • Loading branch information
AJPfleger authored Oct 1, 2024
1 parent 39dfb92 commit 11be339
Show file tree
Hide file tree
Showing 1,986 changed files with 6,008 additions and 6,234 deletions.
6 changes: 3 additions & 3 deletions Alignment/include/ActsAlignment/Kernel/Alignment.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2020-2021 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#pragma once

Expand Down
6 changes: 3 additions & 3 deletions Alignment/include/ActsAlignment/Kernel/Alignment.ipp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2020-2021 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#include "Acts/EventData/VectorMultiTrajectory.hpp"
#include "Acts/EventData/VectorTrackContainer.hpp"
Expand Down
6 changes: 3 additions & 3 deletions Alignment/include/ActsAlignment/Kernel/AlignmentError.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2020 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#pragma once

Expand Down
6 changes: 3 additions & 3 deletions Alignment/include/ActsAlignment/Kernel/AlignmentMask.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2019 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#pragma once

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2020-2021 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#pragma once

Expand Down
6 changes: 3 additions & 3 deletions Alignment/src/Kernel/detail/AlignmentEngine.cpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
// This file is part of the Acts project.
// This file is part of the ACTS project.
//
// Copyright (C) 2020-2021 CERN for the benefit of the Acts project
// Copyright (C) 2016 CERN for the benefit of the ACTS project
//
// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
// file, You can obtain one at https://mozilla.org/MPL/2.0/.

#include "ActsAlignment/Kernel/detail/AlignmentEngine.hpp"

Expand Down
Loading

0 comments on commit 11be339

Please sign in to comment.