-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathgenerate_posts.py
More file actions
46 lines (42 loc) · 3.26 KB
/
Copy pathgenerate_posts.py
File metadata and controls
46 lines (42 loc) · 3.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import random
import glob
import os
usernames = ["alice", "bob", "charlie", "dave",
"eve", "frank", "grace", "heidi", "ivan", "judy"]
captions = [
"Enjoying the retro vibes!",
"Throwback to the 2000s!",
"Windows XP forever!",
"Posting from WinClassic!",
"Just vibing.",
"Love this aesthetic!",
"Simple times.",
"Can't believe this works!",
"Testing scrollbar now.",
"Let's add more posts!",
"Today I dug out my old Windows XP machine and somehow everything still works. It's surprisingly satisfying to use old software again.",
"I forgot how much I missed the Luna theme. The blue taskbar, the green Start button, and the classic sounds bring back so many memories.",
"Spent the afternoon organizing some old photos from 2004. It's amazing how different cameras looked back then compared to today's smartphones.",
"Anyone else remember playing Minesweeper for hours instead of actually getting work done? Good times.",
"This project keeps getting more interesting every week. Every feature added makes it feel a little closer to a real application instead of just a prototype.",
"Working on this inside an actual Windows XP virtual machine somehow makes the whole experience much more authentic. The limitations are frustrating sometimes, but they're also part of the fun.",
"Sometimes I intentionally avoid modern libraries just to see how much can be built using plain Win32 and GDI. It's been a fantastic learning experience so far.",
"One of my favorite parts of this project is watching old APIs come back to life. They're simple, well documented, and surprisingly capable once you understand them.",
"This is a really long caption that should wrap across multiple lines without overlapping the next post. If this renders correctly, then the caption height calculation is probably working exactly as intended.",
"Line one.\\nLine two.\\nLine three.\\nLine four.",
"Here's a paragraph with an intentional newline.\\nBack when computers felt slower, people somehow seemed more patient too.",
"Short line.\\nThis second line is much longer and should wrap naturally onto multiple lines without breaking the layout or overlapping anything below it.",
"Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.",
"The quick brown fox jumps over the lazy dog. This sentence contains every letter of the alphabet and is useful for testing fonts, spacing, and wrapping behavior.",
"If you're reading this, congratulations—you've reached one of the longest captions generated by this script. Keep scrolling and make sure every post is spaced correctly, every scrollbar calculation is accurate, and nothing gets clipped at the bottom!"
]
imgs = []
for file in os.listdir("client/images"):
if file.lower().endswith((".bmp", ".png", ".jpg", ".jpeg")):
imgs.append(file)
with open("client/posts.txt", "w", encoding="utf-8") as f:
for i in range(200): # Generate 30 posts
user = random.choice(usernames)
caption = random.choice(captions)
image = random.choice(imgs)
f.write(f"{user}::{caption}::{image}\n")