Skip to content

Commit b421e3e

Browse files
authored
Merge pull request #16 from BackToBasicsEpita/archetypes
Archetypes
2 parents 2e73bdd + 783d61d commit b421e3e

File tree

12 files changed

+74
-27
lines changed

12 files changed

+74
-27
lines changed

README.md

+23-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## Prérequis
44

5-
Avant de commencer, assurez-vous d'avoir les outils suivants installés sur votre machine :
5+
Avant de commencer, assurez-vous d'avoir les outils suivants installés sur votre machine, si vous utilisez **Nix** vous avez un [flake.nix](flake.nix):
66

77
- [Go](https://go.dev/) (minimum version v1.20)
88
- [Hugo Extended](https://gohugo.io/) (minimum version: 0.120.0)
@@ -12,7 +12,7 @@ Avant de commencer, assurez-vous d'avoir les outils suivants installés sur votr
1212
Clonez le repository du projet :
1313

1414
```sh
15-
git clone https://github.com/BackToBasicsEpita/site.git
15+
git clone git@github.com:BackToBasicsEpita/backtobasicsepita.github.io.git
1616
cd site
1717
```
1818

@@ -25,3 +25,24 @@ Pour lancer le serveur de développement et voir votre site en local :
2525
```
2626

2727
Le site sera disponible à l'adresse : [http://localhost:1313](http://localhost:1313).
28+
29+
## Créer un sujet:
30+
31+
Pour créer un sujet vous aurez la documentation complète sur le site en local [localhost:1313/docs](https://localhost:1313/docs)
32+
33+
Si votre chapitre n'est pas disponible, vous devrez faire :
34+
```sh
35+
hugo -k new chapitre path/to/your/chapitre
36+
```
37+
38+
Sinon/Puis :
39+
40+
```sh
41+
hugo -k new cours path/to/your/course/name
42+
```
43+
44+
## Comment soummettre ma fiche ?
45+
46+
- **Créer une branche pseudo/cours**
47+
- **Faire une pull request**
48+
- **Demander à ce que votre branch soit review et attendre qu'elle soit merge par un membre du bureau**

archetypes/blog/index.md

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
title: "FIXME"
3+
description: "FIXME"
4+
summary: "FIXME"
5+
date: {{ .Date }}
6+
draft: false
7+
weight: 9999
8+
categories: []
9+
tags: []
10+
contributors: ["FIXME"]
11+
cover: "path_of_the_cover/from_resources"
12+
---

archetypes/chapitre/_index.md

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
weight: 999
3+
title: "{{ replace .Name "-" "" | title }}"
4+
description: "FIXME"
5+
icon: "FIXME"
6+
date: {{ .Date }}
7+
draft: false
8+
toc: true
9+
katex: false
10+
---

archetypes/cours/index.md

+6
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,11 @@
22
title: "{{ replace .Name "-" "" | title }}"
33
date: {{ .Date }}
44
authors: ["FIXME"]
5+
weight: 500
6+
description: "FIXME"
7+
icon: "FIXME"
8+
draft: false
9+
toc: false
10+
katex: true
511
---
612

archetypes/rediff.md

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
---
2+
weight: 500
3+
title: "{{ replace .Name "-" "" | title }} - Rediff"
4+
date: {{ .Date }}
5+
description: "Rediff"
6+
draft: false
7+
8+
redif_url: "FIXME"
9+
---

content/blog/presentation/BB.png

-19.5 KB
Binary file not shown.
Binary file not shown.

content/blog/presentation/index.md

+2-9
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,12 @@ title: "BackToBasics est de retour !"
33
description: "Découvrez notre nouveau site, conçu pour vous offrir un accès simplifié à nos cours de soutien, tutorats et événements."
44
summary: "Découvrez notre nouveau site, conçu pour vous offrir un accès simplifié à nos cours de soutien, tutorats et événements."
55
date: 2024-08-22T19:50:00+02:00
6-
lastmod: 2024-08-22T19:50:00+02:00
76
draft: false
87
weight: 50
98
categories: []
109
tags: []
1110
contributors: ["Axel Thauvin"]
12-
pinned: true
13-
homepage: false
14-
seo:
15-
title: "" # custom title (optional)
16-
description: "" # custom description (recommended)
17-
canonical: "" # custom canonical URL (optional)
18-
noindex: false # false (default) or true
11+
cover: "BackToBasics_Horizontal_cover.png"
1912
---
2013

2114

@@ -42,4 +35,4 @@ Pour plus d'informations, explorez notre site, inscrivez-vous à nos événement
4235
**L'équipe BackToBasics**
4336

4437

45-
<img src="BB.png" alt="drawing" width="50"/>
38+
<img src="images/BB.png" alt="drawing" width="50"/>

content/docs/sample-subject/_index.md

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ title: "Example"
44
description: "Sujet d'exemple pour faire un sujet"
55
icon: "function"
66
date: "2023-08-26T20:43:23+01:00"
7-
lastmod: "2023-08-26T20:43:23+01:00"
87
draft: false
98
toc: true
109
katex: false

content/docs/sample-subject/markdown.md

-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ title: "Comment faire du markdown ?"
44
description: "Comment les sujets sont-ils écrits ?"
55
icon: "fluid_med"
66
date: "2023-08-26T20:43:23+01:00"
7-
lastmod: "2023-08-26T20:43:23+01:00"
87
draft: false
98
toc: false
109
katex: true

themes/lotusdocs/layouts/blog/list.html

+5-6
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,11 @@ <h1 class="text-center">{{ .Title }}</h1>
2525
<div class="card">
2626
{{ if site.Params.blog.showImage -}}
2727

28-
{{- $images := .Resources.ByType "image" -}}
29-
{{- $featured := $images.GetMatch "*feature*" -}}
30-
{{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" }}{{ end -}}
31-
{{- if $featured -}}
32-
<img src = "{{ $featured.RelPermalink }}">
33-
{{ end -}}
28+
{{ $link := .RelPermalink }}
29+
30+
{{ with .Params.cover }}
31+
<img src = "{{ $link }}/resources/{{ . }}">
32+
{{ end }}
3433
{{ end -}}
3534
<div class="card-body">
3635
<article>

themes/lotusdocs/layouts/blog/single.html

+7-8
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,13 @@ <h1>{{ .Title }}</h1>
88
</div>
99
</div>
1010
{{ if site.Params.blog.showImage -}}
11-
{{- $images := .Resources.ByType "image" -}}
12-
{{- $featured := $images.GetMatch "*feature*" -}}
13-
{{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" }}{{ end -}}
14-
{{- if $featured -}}
15-
<div class="col-md-13">
16-
<img src = "{{ $featured.RelPermalink }}">
17-
</div>
18-
{{ end -}}
11+
{{ $link := .RelPermalink }}
12+
13+
{{ with .Params.cover }}
14+
<div class="col-md-13">
15+
<img src = "{{ $link }}/resources/{{ . }}">
16+
</div>
17+
{{ end }}
1918
{{ end -}}
2019
<div class="col-md-12 col-lg-9">
2120
{{ with .Params.summary | safeHTML -}}<p class="lead">{{ . }}</p>{{ end -}}

0 commit comments

Comments
 (0)