haskell / win32

Haskell support for the Win32 API
http://hackage.haskell.org/package/Win32
Other
97 stars 62 forks source link

Add API to create symlinks without requiring Administrator privilege #147

Closed TerrorJack closed 4 years ago

TerrorJack commented 4 years ago

Description

Adds a Bool argument to createSymbolicLinkFile/createSymbolicLinkDirectory in System.Win32.SymbolicLink, allowing users to create symlinks without requiring Administrator privilege in the current process.

Motivation and Context

Starting from Windows 10 version 1703 (Creators Update), after enabling Developer Mode, users can create symbolic links without requiring the Administrator privilege in the current process. See the Win32 API documentation of CreateSymbolicLinkW for details.

Types of changes

Checklist:

Mistuke commented 4 years ago

Thanks @TerrorJack! I do wonder though if we should just add a Bool flag to the two existing APIs. I have a slight preference for that.. what do you think?

TerrorJack commented 4 years ago

@Mistuke That would require a major version bump in Win32 right? I also prefer adding Bool flags if you're okay with that.

Mistuke commented 4 years ago

Yes but the version will be bumped for other changes anyway :)

Mistuke commented 4 years ago

So go ahead with the Bool flag!

Mistuke commented 4 years ago

@TerrorJack oh sorry, github didn't send a notification with the new push..Thanks!