Skip to content

always-maap/Despoina

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Despoina 🔮

Despoina, the goddess of Mysteries. daughter of Demeter and Poseidon

Introduction

This is a rust code to send each student's grade privately using lettre to send emails from rust and csv to deal with CSV file of grades and students' names.

Send Grades

As you can see in you should have a sheet like this (if your column names are different feel free to change them in code):

id = "شماره دانشجویی"
name = "نام"
email = "ایمیل"
grade = 100
mistake = "توضیحات"
<html>
  <body dir="rtl">
    <p>
      با سلام<br />
      دانشجوی عزیز {{ name }}<br />
      نمره تمرین شما
    </p>
  </body>
</html>

This is a tera template, and you have variables that is set for each student. Please note that you can check the emails before actually sending them with --dry-run flag.

Enter SMTP/Email Address

Enter your SMTP config and subject in config file.

smtp:
  server: smtp.gmail.com
  username: example@gmail.com
  password: secret
email:
  subject: test

Note that if you use Gmail you must go to your Google account and change Less secure app access here by turning on Allow less secure apps. Otherwise, you need to use application-specific passwords.

Installation

You just need to install rust using rustup.

cp conf.yml.example conf.yml
cargo run -- -c ./conf.yml -f ./results.csv

About

🔮 Sending grades of students privately from .csv file using rust

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages