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

Port before_v0.60/fun folder (issue #221) #835

Merged
merged 10 commits into from
May 13, 2024

Commits on May 12, 2024

  1. move lisp_mode.nu

    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    50ccafe View commit details
    Browse the repository at this point in the history
  2. port lisp_mode.nu

    `def "-" [x, y] { $x - $y }` is a valid syntax but apparently function call not working anymore.
    another functions work well. I wrap them in "" anyway
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    781be89 View commit details
    Browse the repository at this point in the history
  3. move life.nu

    `before_v0.60/fun/life.nu` -> `modules/fun/life.nu`
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    b7fce32 View commit details
    Browse the repository at this point in the history
  4. port life.nu

    - rename all `-` in variable names to `_`
    - replace `nth` with `get`
    - replace `$true` and `$false` with `true`, `false`
    - add `else` to `if {} {}`
    - replace pipeline `for` with `each {|x|...}`
    - replace the table `[[width height data]; ...]` with record `{ width:..., height: ..., data:...}` because there is only one record. (old `nu` was making automatic dereference)
    - `str collect` with `str join`
    - `echo` with `print`
    - clear screen with `clear`
    - remove unnecessary `char nl`
    - remove `main` call at the end
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    f6f2ac0 View commit details
    Browse the repository at this point in the history
  5. move nyancat.nu

    `before_v0.60/fun/nyancat.nu` -> `modules/fun/nyancat.nu`
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    204a5a2 View commit details
    Browse the repository at this point in the history
  6. port nyancat.nu

    - fix frames content: strange `and` to '&'
    - replace removed `char` subcommands
    - make `frames` as a list
    - `for -n` and `nth $it.index` -> `for frame in $frames {}`
    - just `print` each frame
    - `ansi cls` to `clear`
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    ce11629 View commit details
    Browse the repository at this point in the history
  7. move star.nu

    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    2d61244 View commit details
    Browse the repository at this point in the history
  8. port star.nu

    - merge two variants: print each frame at a time
    - implement missing `atan2`
    - use std math `$math.PI`
    - remove `autoview`
    - fix renamed fields in `(term size)`
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    2a35412 View commit details
    Browse the repository at this point in the history
  9. remove spark.nu

    already ported to `sourced/fun/spark.nu`
    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    f1781a4 View commit details
    Browse the repository at this point in the history
  10. move lisp_mode.nu to sourced

    39555 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    726b5dd View commit details
    Browse the repository at this point in the history