Coder Social home page Coder Social logo

csunibo / csurename Goto Github PK

View Code? Open in Web Editor NEW
3.0 3.0 0.0 137 KB

Un piccolo strumento a interfaccia a linea di comando per far sì che i tuoi file rispettino le convenzioni delle risorse di CSUnibo per gli insegnamenti.

License: GNU General Public License v3.0

Rust 100.00%
cli directories files filesystem naming rename

csurename's People

Contributors

dependabot[bot] avatar fossabot avatar foxyseta avatar gadiguibou avatar gentilinigm avatar lucat1 avatar smhmd avatar vaiton avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

csurename's Issues

Rimuovere gli accenti

Nelle regex non accettiamo mai accenti e altri segni grafici non alfanumerici (a meno che non sia il trattino classico). csurename dovrebbe rimuoverli tutti, possibilmente sostituendoli con le loro controparti "semplici". Vista la enorme quantità di caratteri speciali di questo tipo, è altamente preferibile trovare un pacchetto specializzato che lo faccia per noi.

Passare a Clap 4

Al momento usiamo clap 3. Clap 4 introduce cambiamenti dirompenti. See #8.

Analisi della repo

csurename dovrebbe essere usato solo in repo degli insegnamenti, in modo da individuare le varie cartelle e forzare le giuste regexp in base a esse.

Indice dei lucidi

Forzare il kebab case non è abbastanza: nel caso dei lucidi, bisogna anche indovinare un papabile prefisso numerico

Tests

Aggiunta di Unit Tests vari che andranno poi integrati in un eventuale CI.

Al momento organizzerei i tests in questo modo:
.tests/
|-- modules/
| |-- template.rs
| |-- analisi.rs
| `-- ...
|-- integration_tests.rs
`-- common.rs

  • modules/ => i vari insegnamenti con i loro regex e (default) template.
  • integration_tests.rs => i test piu' semplici ed esterni.
  • common.rs => funzioni condivise dai test.

Per i test dei regex si potrebbero usare proprio le pr fallite in passato.

Vari test piu avanzati (come ad esempio per #1 e #7) saranno poi discussi in altre issues o qui.

Testing CLA in rust un buono spunto.

I test dei moduli sono molto utili anche per controllare immediatamente se il rename e' andato a buon fine, senza far fallire una pull request.

Prove

La regexp delle prove sono le più esigenti: richiedono di specificare tipologia, data e testo/soluzione

Eliminare le varie flag

Lo strumento originale include molte flag che però a csurename non servono. Una volta stabili i valori predefiniti che ci interessano (es. ricorsivo, cartelle, etc), potremo procedere a eliminare tutte le flag.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.