Skip to content

Commit 4b6ac19

Browse files
committed
Move fortitude back into its own dir, switch to using requirements.txt and update docs
1 parent dd6affb commit 4b6ac19

File tree

8 files changed

+8
-33
lines changed

8 files changed

+8
-33
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,5 @@ build/
55
build-cmake/
66
*Temporary
77
.vscode
8-
*.egg-info
8+
*.egg-info
9+
.venv

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@ repos:
77
# requires the `--config-file` option to be specified before the `check` subcommand
88
# and the pre-commit hook correctly states check in the entry.
99
- id: fortitude
10-
entry: fortitude --config-file formatting/fortitude.toml check --force-exclude
10+
entry: fortitude --config-file formatting/fortitude/fortitude.toml check --force-exclude

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,11 +108,11 @@ fpm test
108108
[pre-commit](https://pre-commit.com/) is utilised within this repo. pre-commit is a tool to help enforce formatting standards as early as possible.
109109
pre-commit works by running a provided set of checks every time a `git commit` is attempted.
110110

111-
To utilise pre-commit, it must be installed locally. This can be done in several ways but the easiest is to use the provided `pyproject.toml` via...
111+
To utilise pre-commit, it must be installed locally. This can be done in several ways but the easiest is to use the provided `requirements.txt` via...
112112
```
113113
python3 -m venv .venv
114114
source .venv/bin/activate
115-
python -m pip install -e .
115+
python -m pip install -r requirements.txt
116116
```
117117

118118
Then, from the root of the repo, you start using pre-commit by running

formatting/fortitude.md renamed to formatting/fortitude/fortitude.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ A tool for installing, i.e. `pip` or `homebrew`
66

77
## Installation
88

9-
To install fortitude we can utilise the provided `pyproject.toml` by following the instructions in [the pre-commit install instructions](../README.md#pre-commit).
9+
To install fortitude we can utilise the provided `requirements.txt` by following the instructions in [the pre-commit install instructions](../../README.md#pre-commit).
1010
The [quickstart page](https://fortitude.readthedocs.io/en/stable/#quickstart) for Fortitude details multiple other ways of installing the tool.
1111

1212
## Usage in this repo
File renamed without changes.

pyproject.toml

Lines changed: 0 additions & 14 deletions
This file was deleted.

requirements.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
fortitude-lint>=0.7.2
2+
pre-commit>=4.2.0

testing/veggies/test_poisson_given_when_then.f90

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ module veggies_poisson_given_when_then
4444
contains
4545

4646
function test_poisson_given_when_then() result(test)
47-
implicit none
4847
type(test_item_t) :: test
4948

5049
character(len=:), allocatable :: file_name
@@ -73,7 +72,6 @@ function test_poisson_given_when_then() result(test)
7372
end function test_poisson_given_when_then
7473

7574
function load_data_file(input) result(output)
76-
implicit none
7775
class(input_t), intent(in) :: input
7876
type(transformed_t) :: output
7977

@@ -109,7 +107,6 @@ function load_data_file(input) result(output)
109107
end function load_data_file
110108

111109
function check_file_is_open(input) result(result_)
112-
implicit none
113110
class(input_t), intent(in) :: input
114111
type(result_t) :: result_
115112

@@ -122,7 +119,6 @@ function check_file_is_open(input) result(result_)
122119
end function check_file_is_open
123120

124121
function check_num_nodes(input) result(result_)
125-
implicit none
126122
class(input_t), intent(in) :: input
127123
type(result_t) :: result_
128124

@@ -136,7 +132,6 @@ function check_num_nodes(input) result(result_)
136132
end function check_num_nodes
137133

138134
function check_num_elements(input) result(result_)
139-
implicit none
140135
class(input_t), intent(in) :: input
141136
type(result_t) :: result_
142137

@@ -150,7 +145,6 @@ function check_num_elements(input) result(result_)
150145
end function check_num_elements
151146

152147
function check_num_boundary_points(input) result(result_)
153-
implicit none
154148
class(input_t), intent(in) :: input
155149
type(result_t) :: result_
156150

@@ -164,7 +158,6 @@ function check_num_boundary_points(input) result(result_)
164158
end function check_num_boundary_points
165159

166160
function check_element_to_node(input) result(result_)
167-
implicit none
168161
class(input_t), intent(in) :: input
169162
type(result_t) :: result_
170163

@@ -180,7 +173,6 @@ function check_element_to_node(input) result(result_)
180173
end function check_element_to_node
181174

182175
function check_vb_index(input) result(result_)
183-
implicit none
184176
class(input_t), intent(in) :: input
185177
type(result_t) :: result_
186178

@@ -193,7 +185,6 @@ function check_vb_index(input) result(result_)
193185
end function check_vb_index
194186

195187
function check_boundary_node_num(input) result(result_)
196-
implicit none
197188
class(input_t), intent(in) :: input
198189
type(result_t) :: result_
199190

@@ -208,7 +199,6 @@ function check_boundary_node_num(input) result(result_)
208199
end function check_boundary_node_num
209200

210201
function check_num_side_nodes(input) result(result_)
211-
implicit none
212202
class(input_t), intent(in) :: input
213203
type(result_t) :: result_
214204

@@ -225,7 +215,6 @@ function check_num_side_nodes(input) result(result_)
225215
end function check_num_side_nodes
226216

227217
function check_vb(input) result(result_)
228-
implicit none
229218
class(input_t), intent(in) :: input
230219
type(result_t) :: result_
231220

@@ -241,7 +230,6 @@ function check_vb(input) result(result_)
241230
end function check_vb
242231

243232
function check_vb1(input) result(result_)
244-
implicit none
245233
class(input_t), intent(in) :: input
246234
type(result_t) :: result_
247235

@@ -254,7 +242,6 @@ function check_vb1(input) result(result_)
254242
end function check_vb1
255243

256244
function check_coordinates(input) result(result_)
257-
implicit none
258245
class(input_t), intent(in) :: input
259246
type(result_t) :: result_
260247

@@ -274,7 +261,6 @@ end function check_coordinates
274261
!! Constructors
275262
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
276263
function data_file_state_constructor() result(data_file_state)
277-
implicit none
278264
type(data_file_state_t) :: data_file_state
279265

280266
integer, parameter :: file_io = 200

0 commit comments

Comments
 (0)