Skip to content

Comments

Refactor file structure#1

Closed
lishaduck wants to merge 29 commits intoinfinityJKA:mainfrom
lishaduck:lishaduck-patch-1
Closed

Refactor file structure#1
lishaduck wants to merge 29 commits intoinfinityJKA:mainfrom
lishaduck:lishaduck-patch-1

Conversation

@lishaduck
Copy link

@lishaduck lishaduck commented Dec 16, 2022

Also, fixes current_directory/cwd error, and rewrites the readme to use markdown, @infinityJKA. Reformats the code with black, sorts imports with isort, and manages dependencies with poetry. Adds a gitignore. Adds status checks.

Comment on lines +8 to +11
- package-ecosystem: "pip" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Checks for dep updates daily

Comment on lines +2 to +3
#save.dat
#autosave.dat
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
#save.dat
#autosave.dat
save.dat
autosave.dat

Comment on lines +11 to +28
| Key | Mapping |
| ---------- | --------------- |
| 1 | SAVE |
| 2 | TOGGLE SIDESTEP |
| 3 | STAT |
| 4 | KEY ITEMS |
| q | A |
| e | B |
| w | UP |
| r | EQUIP |
| t | PARTY |
| a | LEFT |
| s | DOWN |
| d | RIGHT |
| f | ITEM |
| g | TALK |
| arrow keys | movement |
| space key | for TALK |
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Converted the list to a table

@@ -0,0 +1,4 @@
"""Bipole V! A game.

TODO: Ought BipoleV.py to be renamed to __init__.py, and replace this?
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

?

pyproject.toml Outdated
Comment on lines 9 to 11
numpy = "^1.23.5"
pillow = "^9.3.0"
python = "^3.10"
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dependencies for the project.

@@ -0,0 +1,33 @@
[tool.poetry]
authors = ["InfinityJKA <jkajustin@gmail.com>"]
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this the right email?


from PIL import Image, ImageTk

current_directory: Path = Path(os.path.realpath(__file__)).parent
Copy link
Author

@lishaduck lishaduck Dec 16, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a better way to get the file's location, @infinityJKA.

Comment on lines +1323 to +1329
file_contents = open(
current_directory
/ "dialogue"
/ maps.current_location[4]
/ (input_file + ".txt"),
encoding="UTF-8",
)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use the '/' operator to append strings to a path, @infinityJKA.
Oh, and when opening in text ("t") mode, always specify an encoding.

@lishaduck
Copy link
Author

What did you use to build the output folder, @infinityJKA?

@infinityJKA
Copy link
Owner

infinityJKA commented Dec 19, 2022 via email

I tried it, and it seemed to work.
However, I'm on a managed mac, so I'm not sure.
It wouldn't let me run it.
@lishaduck
Copy link
Author

I think packaging works now, @infinityJKA. The only thing would be uploading the build artifacts to releases. I'd think there's a way to automate it, but I don't see one.

auto-py-to-exe is a thin *graphical* wrapper over pyinstaller.
However, we aren't we aren't using npm and puppeteer, so we need to use pyinstaller ourselves.
@lishaduck
Copy link
Author

Packaging should be fixed now, @infinityJKA.

@lishaduck
Copy link
Author

Should I break this into smaller PRs, 1 at a time, @infinityJKA?

@infinityJKA
Copy link
Owner

Should I break this into smaller PRs, 1 at a time, @infinityJKA?

Idk, if you want

@lishaduck
Copy link
Author

I've decided that I'm too busy to update this, and it's useless in this condition, so I'm closing it.

@lishaduck lishaduck closed this Apr 24, 2023
@infinityJKA
Copy link
Owner

real

@lishaduck
Copy link
Author

I'm going to prune the repo at the very least now that I can run it again. I'll try to be more conservative this time.

@infinityJKA
Copy link
Owner

@lishaduck should i be scared

@lishaduck
Copy link
Author

No. I'm going 1 commit @ a time

@infinityJKA
Copy link
Owner

Remember to commit responsibly!

@lishaduck
Copy link
Author

lishaduck commented Oct 24, 2023

I've double checked, #2 still works fully on a managed mac w/py3.11.6!

@lishaduck
Copy link
Author

#3 is just docs, but I checked anyway, and it too works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants