GitHub Action commited on
Commit
3f7edae
·
1 Parent(s): ecf2c66

Sync from GitHub with Git LFS

Browse files
Files changed (1) hide show
  1. scripts/publish_to_hashnode.py +3 -3
scripts/publish_to_hashnode.py CHANGED
@@ -71,7 +71,7 @@ def create_post(title, slug, markdown_content):
71
  mutation CreateDraft($input: CreateDraftInput!) {
72
  createDraft(input: $input) {
73
  draft {
74
- _id
75
  slug
76
  title
77
  }
@@ -94,7 +94,7 @@ def update_post(post_id, title, slug, markdown_content):
94
  mutation UpdateDraft($id: ID!, $input: UpdateDraftInput!) {
95
  updateDraft(id: $id, input: $input) {
96
  draft {
97
- _id
98
  slug
99
  title
100
  }
@@ -139,7 +139,7 @@ def main(force=False):
139
  post = create_post(name, slug, md_text)
140
  print(f"🆕 Пост опубликован: https://hashnode.com/@yourusername/{post['slug']}")
141
 
142
- published[name] = {"id": post["_id"], "slug": post["slug"], "hash": h}
143
  save_published(published)
144
 
145
  print("⏱ Пауза 30 секунд перед следующим постом...")
 
71
  mutation CreateDraft($input: CreateDraftInput!) {
72
  createDraft(input: $input) {
73
  draft {
74
+ id
75
  slug
76
  title
77
  }
 
94
  mutation UpdateDraft($id: ID!, $input: UpdateDraftInput!) {
95
  updateDraft(id: $id, input: $input) {
96
  draft {
97
+ id
98
  slug
99
  title
100
  }
 
139
  post = create_post(name, slug, md_text)
140
  print(f"🆕 Пост опубликован: https://hashnode.com/@yourusername/{post['slug']}")
141
 
142
+ published[name] = {"id": post["id"], "slug": post["slug"], "hash": h}
143
  save_published(published)
144
 
145
  print("⏱ Пауза 30 секунд перед следующим постом...")