Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a few lines to frontend .gitignore files. #2559

Merged
merged 4 commits into from
Jan 6, 2021

Conversation

merivale
Copy link
Contributor

This PR just adds a couple of quality of life improvements for frontend development, by adding three lines to each of the relevant .gitignore files.

  1. Having '/generated' as well as '/generated/' lets you use a symlink to your nix store (or whatever) instead of a directory with a copy of the generated PureScript.
  2. 91394e9 changed the setup from Yarn to NPM. Adding '/yarn.lock' (and restoring '/yarn-error.log') lets you carry on using Yarn locally if you want to. Then everybody's happy. 😄

Copy link
Contributor

@krisajenkins krisajenkins left a comment

Choose a reason for hiding this comment

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

LGTM. As long as CI is happy, I'm happy.

Copy link
Contributor

@shmish111 shmish111 left a comment

Choose a reason for hiding this comment

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

Ditto Kris

@michaelpj
Copy link
Contributor

These folders all look pretty generic - I think we could probably stuff most of this into the root gitignore with some wildcard patterns and get rid of the duplication? e.g. put **/node_modules/ in the root .gitignore.

@merivale
Copy link
Contributor Author

merivale commented Jan 4, 2021

Good point @michaelpj. Does anyone know if any of these aren't generic? I'd be tempted to just put them all in the root .gitignore and be done with it. Similarly, I've just noticed the root .gitignore file includes marlowe-playground-server/playground.yaml, but plutus-playground-client/playground.yaml is included in the plutus-playground-client/.gitignore file instead.

@michaelpj
Copy link
Contributor

Similarly, I've just noticed the root .gitignore file includes marlowe-playground-server/playground.yaml, but plutus-playground-client/playground.yaml is included in the plutus-playground-client/.gitignore file instead.

Seems like an argument for consolidating it!

I can see the argument for directory-specific gitignore files if it's really stuff that's only specific to that folder, otherwise you get lots of sections in the root gitignore. But in this case the ability to generalize seems nice.

@merivale
Copy link
Contributor Author

merivale commented Jan 4, 2021

Let me know what you all think of this then please. There appeared to be a few redundancies once I started looking.

@shmish111
Copy link
Contributor

I think until things get out of hand, a single gitignore makes more sense

@@ -1,6 +1,9 @@
/node_modules/
Copy link
Contributor

Choose a reason for hiding this comment

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

Kill this one too?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, I thought I did. Well spotted, thanks.

@merivale
Copy link
Contributor Author

merivale commented Jan 5, 2021

Does someone know how to get this past CI? I'm afraid I don't. It's complaining that the .gitignore files I've removed don't exist.

@michaelpj
Copy link
Contributor

Ah, I think this was @gilligan trying to be smart and selectively filter the sources per-directory. I think we should just pass the filtered source in, tbh. Give me a sec and I'll take a look.

@michaelpj
Copy link
Contributor

Hm, not quite as obvious as I'd hoped. Still thinking.

@michaelpj
Copy link
Contributor

  • nix-gitignore doesn't read .gitignores in parent directories.
  • Passing in a filtered source for the root and then extending the path to get a subdirectory doesn't seem to work.
  • hercules-ci/gitignore.nix does read gitignores in parent directories, but it slows down our eval atm (I already tried it in Switch to hercules-ci/gitignore.nix for a cool 2x eval speedup #2512)

I'm having another look at gitignore.nix, in the mean time I suggest just putting the directory-specific ones back to unblock this.

@merivale
Copy link
Contributor Author

merivale commented Jan 5, 2021

Ok, thanks Michael. I'll do that for now, and if you think of something on the CI issue we can remove them later.

@merivale merivale merged commit 8832067 into master Jan 6, 2021
@merivale merivale deleted the frontend-gitignore-tweaks branch January 6, 2021 15:13
merivale added a commit that referenced this pull request Jan 7, 2021
* Adding a few lines to frontend .gitignore files.

* Removing playground and web-common .gitignore files, and generalising root .gitignore file instead.

* Removing redundant SCB client .gitignore file.

* Putting back (regimented) frontend .gitignore files for now, to satisfy CI.
merivale added a commit that referenced this pull request Jan 7, 2021
* Moving around some CSS files.

There are no actual changes here. Just file-tidying.

* WIP: UI Redux.

* Frontend: Enabling Vim mode will now show a statusline.

* Adding some JSLine config lines to Marlowe.

* Git-ignoring your local playground config files.

* Fixing the gitignore rules for the frontend `generated` directories.

We were git-ignoring `/generated/`. That works as expected when
`generated` is a directory, but not when it’s a symlink to a directory.

* Fixing some new SCSS variables that were missing from plutus-scb-client.

* Refactoring View.purs, in preparation for moving things around and restyling.

* Restyling header and footer, swapping PNG logo for SVG, and tidying CSS a bit.

* Moving gist controls to the subheader, shifting editor preferences to the right, and adding a second compile button above the editor.

* fixup! Frontend: Enabling Vim mode will now show a statusline.

* Restyling the editor and tidying up some CSS.

* Renaming simulation tab to 'simulations', and changing simulation selection buttons to tabs.

* Splitting the common Gists module into types and views.

* Separating Bootstrap imports out of .

* Refactoring the chain.scss to abstract out the colour choices.

* Fixing fontawesome times/close icon class (fontawesome 5 removed the 'close' alias).

* Restyling the editor and simulator to (start to) match the new designs (and temporarily breaking the transactions view in the process).

* Simplifying gistControls view.

* Adding a missing full stop in a comment.

* Modifying simulations view, and separating the actionsPane into its own module.

* Getting the simulations view closer to the target.

* Removing unnecessary action argument from editor buttons.

* Tidying the transactions view and getting it closer to the new UX specification.

* Tidying simulations and transactions headers, styling Gist error popup.

* Making editor feedback pane minimisable.

* Making demo files menu toggle open/closed (not styled yet).

* FE: Triggering a re-layout whenever Monaco's keybindings change.

...as this can change parts of the display like the status line.

* Removing some unused references.

* Plutus Playground: Fixing keybinding tracking.

The localstorage setting was updated correctly, but the in-memory flag
was not.

* FE: Disabling the minimap.

* Moving the evaluation errors pane out of the main view and into the simulations view, and making it look a bit nicer.

* Further modifying the Gist widget to bring it closer to the UX specification.

* Removing '#'s from simulation/wallet/slot names.

* Removing text from under evaluate/transactions buttons.

* Improving compilation status bar look and behaviour.

* Changed successful compilation message.

* Restyled small screen demo files menu.

* Disabling transaction button when simulation changes.

* Finishing styling of simlation tabs.

* Restyling all over to make sure everything matches the design exactly.

* Improving simulations tabs, and fixing event propogation bug introduced by moving the close button inside the tab.

* A couple of little modifications to the transactions view.

* FE: Adding a utility to call JS's window.scrollIntoView.

* Simplifying editorWrapper code.

* Scrolling simulation errors and transactions into view on (un)successful evaluation.

* Removing some unnecessary comments that helped me find my way around when I started.

* Better fudging of the problem caused by only have one set of transactions in the model.

* Making empty strings valid (because `Nothing` and `Just ""` are indistinguishable in the browser).

* Improving action wallet validation.

* Removing some unnecessary imports.

* Disabling simulate button when code changes after successful compilation.

* Adding another case to the editor feedback text.

* fixup! Scrolling simulation errors and transactions into view on (un)successful evaluation.

* Making Gist ajax error pane closeable.

* Removing hashes and arrows from blockchain visualisation.

* Making the blockchain visualisation a bit nicer to look at.

* Highlighting current demo file.

* Switching to editor view when Gist is loaded.

* fixup! Making Gist ajax error pane closeable.

* Improving temporary fudge to make simulations/transactions UX sensible, in advance of proper remodelling of the state.

* fixup! Disabling simulate button when code changes after successful compilation.

* Adding isValid function to Validation.purs.

* Refactoring and improving action validation.

* Tidying and rationalising view function arguments and type signatures.

* Tidying actions view a bit.

* Making it impossible to create more than 10 wallets in simulations.

* Running fix-purty.

* Making assorted improvements in response to review comments.

* Running fix-purty and removing an unused function.

* One fix, one tiny bit of tidying.

* SCP-1541 Implement the redesign of "open project" dialog (#2551)

* Marlowe playground FE: Implement redesign of open project

* Marlowe playground FE: Make modal header sticky

* Fix open project modal padding

* Add global loading indicator

* Fix error when you have gists but that are not playground gists

* Make the open project dialog full width always

* Global loading indicator should not appear in saving as modal

* Make the open project modal always to occupy full width

* Applied PR feedback

* Applied PR feedback

* niv pre-commit-hooks.nix: update d16e007e -> ac3a4ca0

## Changelog for pre-commit-hooks.nix:
Branch: master
Commits: [cachix/git-hooks.nix@d16e007e...ac3a4ca0](cachix/git-hooks.nix@d16e007...ac3a4ca)

* [`908bbd60`](cachix/git-hooks.nix@908bbd6) Add Fourmolu
* [`5fa5c3a5`](cachix/git-hooks.nix@5fa5c3a) Add hunspell to check for spelling mistakes

* Breaks compilation with haddock enabled.

* niv-updater: also blacklist nixpkgs

See comment in the workflow. It's basically always a mass-rebuild, and
it doesn't gain us much.

I considered just making the updater action run less frequently, but I
don't think we even want to update it every month!

* Analytics name fix (#2569)

* Renaming handleActionWithAnalyticsTracking to withAnalytics.

* Replacing some PP analytics functions with ones from web-common.

* Renaming handleAction' to handler.

* SCP-1517 unsaturated builtins for extrinsically typed syntax/semantics (#2556)

* removing saturated builtins from Extrinsic syntax + ren/sub

* some signature equipment

* progress: term arg saturation step

* progress: beta-builtin

* progress: type applications

* interleaved telescopes

* progress: ival

* progress

* CK: computation case

* CK

* erasure + removing old builtins from typechecker

* semantics of builtins

* removing old builtin semantics

* Renaming module Playground.Schema to Schema.View. (#2567)

* niv easy-purescript-nix: update 860a95cb -> c8c32741

## Changelog for easy-purescript-nix:
Branch: master
Commits: [justinwoo/easy-purescript-nix@860a95cb...c8c32741](justinwoo/easy-purescript-nix@860a95c...c8c3274)

* [`c5d989d5`](justinwoo/easy-purescript-nix@c5d989d) Spago 0.18.1

* niv mvn2nix: update a4c9ec1c -> 9348fc40

## Changelog for mvn2nix:
Branch: master
Commits: [fzakaria/mvn2nix@a4c9ec1c...9348fc40](fzakaria/mvn2nix@a4c9ec1...9348fc4)

* [`9348fc40`](fzakaria/mvn2nix@9348fc4) Updated github actions ([fzakaria/mvn2nix⁠#32](http://r.duckduckgo.com/l/?uddg=https://github.com/fzakaria/mvn2nix/issues/32))

* niv pre-commit-hooks.nix: update ac3a4ca0 -> c7e3896e

## Changelog for pre-commit-hooks.nix:
Branch: master
Commits: [cachix/git-hooks.nix@ac3a4ca0...c7e3896e](cachix/git-hooks.nix@ac3a4ca...c7e3896)

* [`fcfb9450`](cachix/git-hooks.nix@fcfb945) Add html-tidy for HTML validation
* [`f29bddb9`](cachix/git-hooks.nix@f29bddb) Add documentation for custom user defined hooks

* Fix annoyance in output of serialised code in PLC command

* webghc (and docker image) was broken (#2577)

* Marlowe Playground Frontend: Separate simulator from marlowe editor (#2560)

* Created a new view for MarloweEditor
* Fixed keybinding selector for marlowe editor
* Moved linter, holes and initial marker logic from simulation to marlowe editor
* Fix double provider information
* Renamed Simulation modules
* Separated simulation bottom panel and actions

The bottom panel in the MarloweEditor is commented as it’s very tied to the simulation. It will be restored in a future commit of this refactor

* Fix bottom panel in marlowe editor
* Fix simulation language color
* Make the simulation editor readonly
* Renamed _marloweEditorSlot to _simulatorEditorSlot
* Reimplement workflow buttons
* Move select hole to MarloweEditor
* Fix simulation state on refresh
* Remove unused code from Marlowe editor bottom panel
* redesign simulation right pane
* Fix file actions not being shown in Marlowe editor
* Remove isValidContract from the simulation as it should always be valid
* Fix undo button problem
* Improved how we show a slot range

* Add NFData instances for Tx and ChainState

* Correcting an out-of-date reference in the PR template.

* Adding a few lines to frontend .gitignore files. (#2559)

* Adding a few lines to frontend .gitignore files.

* Removing playground and web-common .gitignore files, and generalising root .gitignore file instead.

* Removing redundant SCB client .gitignore file.

* Putting back (regimented) frontend .gitignore files for now, to satisfy CI.

* Fixing some problems caused by a bad merge resolution.

* Fixing some problems with out UUID types being invalid.

The UUID validation rules are not as simple as we first thought.

* Correcting the JSON instances for Plutus.Trace.Tag.

Co-authored-by: Kris Jenkins <kris.jenkins@tweag.io>
Co-authored-by: Hernan Rajchert <hrajchert@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Radu Ometita <radu.ometita@gmail.com>
Co-authored-by: Michael Peyton Jones <michael.peyton-jones@iohk.io>
Co-authored-by: James Chapman <james.chapman@iohk.io>
Co-authored-by: kwxm <kenneth.mackenzie@iohk.io>
Co-authored-by: David Smith <shmish111+github@gmail.com>
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.

5 participants