Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
71 changes: 0 additions & 71 deletions .github/workflows/run.yml

This file was deleted.

7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -482,3 +482,10 @@ $RECYCLE.BIN/
.idea/
.idea/*


data
dati
RankingsDati
rankingsdati
output
dist
49 changes: 47 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,70 @@
Rewrite in C# della repo https://github.com/PoliNetworkOrg/GraduatorieScript

## Requirements

- [dotnet sdk >= 7.0](https://dotnet.microsoft.com/en-us/download/dotnet/7.0)
- [git](https://git-scm.com/downloads)

### Ubuntu
> Note: this may upgrade older versions installed

> Note: this may upgrade older versions installed

```sh
sudo apt-get update && sudo apt-get install dotnet-sdk-7.0 git
```

## Quickstart

1. get git submodules (libraries)

```sh
git submodule update --init --recursive
```

2. install dotnet deps

```sh
dotnet restore
```

3. run

```sh
dotnet run --project GraduatorieScript
dotnet run --project PoliNetwork.Graduatorie.Parser
```

Projects:
- `PoliNetwork.Graduatorie.Scraper` scrapes links from PoliMi and obtain html
- `PoliNetwork.Graduatorie.Parser` runs scraper then parses html into objects/json

Parameters:
- `--reparse` regenerate all rankings files (use it when make changes to data structure)
- `--data dir` specify where is the data folder

### Data folder

Data folder has been moved to [RankingsDati](https://github.com/PoliNetworkOrg/RankingsDati)
in [#128](https://github.com/PoliNetworkOrg/GraduatorieScriptCSharp/issues/128)
therefore the script won't find it.

**Clone this repo and RankingsDati** then follow one of these two methods:

- Run the script specifying where is the data folder with the `--data dir` param.

```sh
dotnet run --project PoliNetwork.Graduatorie.Parser --data ../RankingsDati/data
```

- Create a symbolic link inside the script repo pointing to the data folder inside RankingsDati
so that the script would find it independently.

```sh
ln -s ../RankingsDati/data/
dotnet run --project PoliNetwork.Graduatorie.Parser
```

Git should ignore the link created (because `data` is inside `.gitignore`)

The script output will be in the data folder found (copied on reference).
**In both cases you may check that RankingsDati is up-to-date to avoid
false positive or incomplete output.**
65 changes: 0 additions & 65 deletions data/dateFound.json

This file was deleted.

2 changes: 0 additions & 2 deletions data/html/2020_20002_html/2020_20002_generale.html

This file was deleted.

Loading