Skip to content

Commit 2f49a0d

Browse files
phgrosjeanMichaelChiricotdhockToby Dylan Hocking
authored
French translation (vignettes) (#6455)
Co-authored-by: Michael Chirico <[email protected]> Co-authored-by: Toby Dylan Hocking <[email protected]> Co-authored-by: Toby Dylan Hocking <[email protected]> Co-authored-by: Toby Dylan Hocking <[email protected]>
1 parent 08e94b7 commit 2f49a0d

23 files changed

+4007
-1
lines changed

.Rbuildignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.dir-locals.el
2+
.check.translations.R
23
^\.Rprofile$
34
^data\.table_.*\.tar\.gz$
45
^config\.log$

DESCRIPTION

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,5 +92,10 @@ Authors@R: c(
9292
person("Ivan", "Krylov", role="ctb"),
9393
person("Angel", "Feliz", role="ctb"),
9494
person("Michael","Young", role="ctb"),
95-
person("Mark", "Seeto", role="ctb")
95+
person("Mark", "Seeto", role="ctb"),
96+
person("Philippe", "Grosjean", role="ctb"),
97+
person("Vincent", "Runge", role="ctb"),
98+
person("Christian", "Wia", role="ctb"),
99+
person("Elise", "Maigné", role="ctb"),
100+
person("Vincent", "Rocher", role="ctb")
96101
)

vignettes/.check.translations.R

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
library(data.table)
2+
translated.Rmd <- Sys.glob("*/*.Rmd")
3+
rm_suffix <- function(x)sub("[.][^.]+$", "", x)
4+
trans.dt <- data.table(
5+
lang=dirname(translated.Rmd),
6+
trans_file=rm_suffix(basename(translated.Rmd)))
7+
en.dt <- data.table(en.Rmd=Sys.glob("*.Rmd"))[
8+
, en_file := rm_suffix(en.Rmd)
9+
][]
10+
link.dt <- en.dt[, nc::capture_all_str(
11+
en.Rmd,
12+
"https://rdatatable.gitlab.io/data.table/articles/",
13+
lang=".*?",
14+
"/",
15+
trans_file=".*?html", rm_suffix
16+
), by=en_file]
17+
maybe_err <- function(dt,msg){
18+
if(nrow(dt)){
19+
cat(msg,":\n")
20+
print(dt)
21+
}
22+
}
23+
maybe_err(link.dt[en_file != trans_file],"typos in links")
24+
files.join <- trans.dt[en.dt, .(
25+
langs=paste(lang[!is.na(lang)],collapse=",")
26+
), on=.(trans_file=en_file), by=.EACHI]
27+
maybe_err(files.join[nchar(langs)<max(nchar(langs))], "missing translation files")

vignettes/datatable-benchmarking.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ h2 {
2525
}
2626
</style>
2727

28+
Translations of this document are available in
29+
30+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-benchmarking.html)
31+
2832
This document is meant to guide on measuring performance of `data.table`. Single place to document best practices and traps to avoid.
2933

3034
# fread: clear caches

vignettes/datatable-faq.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ h2 {
2626
}
2727
</style>
2828

29+
Translations of this document are available in
30+
31+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-faq.html)
32+
2933
```{r, echo = FALSE, message = FALSE}
3034
library(data.table)
3135
knitr::opts_chunk$set(

vignettes/datatable-importing.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ h2 {
1515
}
1616
</style>
1717

18+
Translations of this document are available in
19+
20+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-importing.html)
21+
1822
This document is focused on using `data.table` as a dependency in other R packages. If you are interested in using `data.table` C code from a non-R application, or in calling its C functions directly, jump to the [last section](#non-r-api) of this vignette.
1923

2024
Importing `data.table` is no different from importing other R packages. This vignette is meant to answer the most common questions arising around that subject; the lessons presented here can be applied to other R packages.

vignettes/datatable-intro.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ vignette: >
99
\usepackage[utf8]{inputenc}
1010
---
1111

12+
Translations of this document are available in
13+
14+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-intro.html)
15+
1216
```{r, echo = FALSE, message = FALSE}
1317
require(data.table)
1418
knitr::opts_chunk$set(

vignettes/datatable-keys-fast-subset.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ vignette: >
99
\usepackage[utf8]{inputenc}
1010
---
1111

12+
Translations of this document are available in
13+
14+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-keys-fast-subset.html)
15+
1216
```{r, echo = FALSE, message = FALSE}
1317
require(data.table)
1418
knitr::opts_chunk$set(

vignettes/datatable-programming.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ vignette: >
99
\usepackage[utf8]{inputenc}
1010
---
1111

12+
Translations of this document are available in
13+
14+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-programming.html)
15+
1216
```{r init, include = FALSE}
1317
require(data.table)
1418
knitr::opts_chunk$set(

vignettes/datatable-reference-semantics.Rmd

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ vignette: >
99
\usepackage[utf8]{inputenc}
1010
---
1111

12+
Translations of this document are available in
13+
14+
* [French](https://rdatatable.gitlab.io/data.table/articles/fr/datatable-reference-semantics.html)
15+
1216
```{r, echo = FALSE, message = FALSE}
1317
require(data.table)
1418
knitr::opts_chunk$set(

0 commit comments

Comments
 (0)