ajout vidéos, et posts sur jeux de données

This commit is contained in:
Tykayn 2024-11-26 12:48:25 +01:00 committed by tykayn
parent 52173f3843
commit c674871d78
11 changed files with 128 additions and 60 deletions

View file

@ -13,7 +13,7 @@ parser.add_argument("lang", help="La langue de l'article.")
parser.add_argument("title", help="Le titre de l'article.")
args = parser.parse_args()
uuid_value=''
# Génération du nom de fichier org avec la date et le slug
now = datetime.now()
# date_string = now.strftime("%Y-%m-%d")
@ -32,28 +32,26 @@ def create_uuid_property():
return f":PROPERTIES:\n:ID: {uuid_value}\n:END:\n"
# Écriture du fichier org
with open(filename, "w") as f:
f.write(f"{create_uuid_property()}")
f.write(f"#+title: {args.title}\n")
f.write(f"#+CREATED: <{date_string_full}>\n")
f.write(f"#+TAGS: \n")
f.write(f"#+SLUG: {slug}\n")
f.write(f"#+BLOG: {args.blog_dir}\n\n")
f.write(f"* {args.title}\n\n")
# f.write(f"[{date_string}]\n\n")
#+title: de-lisolement-social-et-des-choix-de-vie
#+post_ID: 2719
#+post_slug: de-lisolement-social-et-des-choix-de-vie
#+post_url: https://tykayn.fr/2021/de-lisolement-social-et-des-choix-de-vie
#+post_title: De Lisolement social et des choix de vie
with open(filename, "w") as f:
f.write(f"""
#+title: {slug}
#+post_ID:
#+post_slug: organisation-de-taches-orgmode
#+post_url: https://www.ciperbliss.com/2024/{slug}
#+post_title: {args.title}
#+post_tags:
#+post_type: post
#+post_mime_types:
#+post_guid: https://tykayn.fr/?p=2719
#+post_mime_types:
#+post_guid:
#+post_status: publish
#+post_date_published: <2021-10-26 13:06:34>
#+post_date_modified: <2021-10-26 13:06:34>
#+post_index_page_roam_id: f7fe8338-4738-4934-9038-35a004ca3786
#+post_date_published: <{date_string_full}>
#+post_date_modified: <{date_string_full}>
#+post_index_page_roam_id: {uuid_value}
#+BLOG: cipherbliss_blog {args.blog_dir}
* {args.title}
""")
print(f"Le fichier '{filename}' a été créé avec succès.")