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

Get current file untitled support #2841

Merged
merged 6 commits into from
Nov 8, 2024
Merged

Conversation

RomneyDa
Copy link
Collaborator

@RomneyDa RomneyDa commented Nov 7, 2024

Description

Current pattern is getCurrentFile -> readCurrentFile

The problem is if it's untitled there's no way to deduce that reliably from a single path

Also in every single use case, getCurrentFile read the file contents

So I just made getCurrent file return the file contents

Adjusted some types here and there

isUntitled is unused at the moment

Checklist

  • The base branch of this PR is dev, rather than main
  • The relevant docs, if any, have been updated or created

Fixes #2798
#1226 seems related but as far as I can tell it's already been fixed

Copy link
Contributor

@sestinj sestinj left a comment

Choose a reason for hiding this comment

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

Nice application of the augmenting data types to solve problems principle

@sestinj sestinj merged commit 3e5044b into dev Nov 8, 2024
1 check failed
@sestinj sestinj deleted the dallin/current-untitled-file branch November 8, 2024 23:47
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.

3 participants