Sudha247 / ocaml-joy

MIT License
22 stars 14 forks source link

Joy Example: A grid of circles #29

Closed Sudha247 closed 7 months ago

Sudha247 commented 1 year ago

With Joy.Shape, create a grid of four circles. There's a similar example with plain graphics that needs to be ported to joy.

TitilayoAdeyemi commented 1 year ago

Hello @Sudha247 I'd be happy to work on this.

TitilayoAdeyemi commented 1 year ago

I am done with this already, do you want the circles filled with color? Or just plain?

nikochiko commented 1 year ago

@TitilayoAdeyemi can you create a pull request with your changes and mention a link to this issue in its description?

TitilayoAdeyemi commented 1 year ago

Hi @nikochiko I'm sorry, there was an oversight. I did it without using the Joy.shape How do I implement it using Joy.shape?

nikochiko commented 1 year ago

You'll need to use circle and translate in your example... Use circle like this -- https://github.com/Sudha247/ocaml-joy/blob/c24273e548175e65c6185fcee1fcfd41a5d8eec8/test/test_circle.ml#L5-L6 Use translate like this -- https://github.com/Sudha247/ocaml-joy/blob/main/examples/translate_circle.ml#L9

nikochiko commented 1 year ago

You'll need to pull the latest changes because translate was just merged in.

TitilayoAdeyemi commented 1 year ago

Hi @nikochiko I am facing an error while trying to push my code I have followed the link that was in the terminal but it does not provide information as to what is wrong Screenshot (113)

nangahamandine commented 1 year ago

Hi @nikochiko I am facing an error while trying to push my code I have followed the link that was in the terminal but it does not provide information as to what is wrong Screenshot (113)

Hi @TitilayoAdeyemi it's an authentication error so try pushing your commits again. After inputting your username, they'll request for your password but don't use your github password because support for password authentication had been removed. Rather, go to your github account and create a personal access token that you can use for the next month or year however you please. Just make sure that it doesn't expire anytime. In the place of the password, always use that personal access token for authentication. You can always copy it and paste somewhere in your local machine so that you don't lose it after creating it. And also, since the password is not displayed when you type it in your terminal, it's best to store your personal access token somewhere where you can easily copy it and paste with ease.

This is what I've been doing for a while now and it works perfectly fine, don't know if there's another way to go about it.

TitilayoAdeyemi commented 1 year ago

Thank you @nangahamandine I tried it but its now returning a 403 Screenshot (114)

nangahamandine commented 1 year ago

Did you successfully create the personal access token?

TitilayoAdeyemi commented 1 year ago

Yes, I did. I don't think the problem is with the access token, the error message says I do not have permission to push to the repository

nangahamandine commented 1 year ago

Oh I just realized that you're trying to push your code directly to the main repo. You have to actually create you're own fork of the repo and make contributions to your fork before opening a PR. You wouldn't be able to contribute directly to the main repo.

TitilayoAdeyemi commented 1 year ago

Hi @nikochiko I have created a pull request for this, would be glad to have you review my code.