SPM Improve CLI User Experience

Hi, I am Mojito, a software student from Korea!

I am developing iOS application using swift. Here's my githeub address: MojitoBar (judongseok) · GitHub
I am interested in the Improve CLI User Experience project at GSoC.
I could find the list below by referring to some threads.

  • Audit inputs for consistency on language and style

  • Making options type safe

  • Logical grouping

  • Expanding and improving the help and usage explanations

  • Audit output options for consistency (e.g. output format option)

  • Improved progress indicators

  • Improved duration tracking and reporting

  • For concurrent work, present output from active task per worker / thread

  • Provide additional contextual information for warnings and errors

  • Graphical output for dependency graphs

  • General modernization the output - adopting modern CLI UX/UI best practices

Do we have to implement all of the list?
I have some iOS application development experience and CLI experience through vapor, cocoapod, etc.
Would it be enough for me to carry out the project?

If you don't mind, I'd appreciate some advice for writing a proposal.

Thank you for opening up an opportunity to contribute to open source!

@NeoNacho @abertelrud @tomerd

3 Likes

Hi @MojitoBar and thank you for your interest in the project.

SwiftPM is Swift's dependency management tool and can be used from the command line and from IDEs.
The project focus is on improving the command line experience which boils down to two parts:

  1. Input: How users pass arguments, options, flags and get help around these.
  2. Output: How SwiftPM emits output to users which includes direct output, indirect output (side effects), progress, errors and warnings.

For user input, SwiftPM uses Swift Argument Parser (GitHub - apple/swift-argument-parser: Straightforward, type-safe argument parsing for Swift ) - a library that helps parse command line arguments.
Potential improvements in this context are mostly optimizing the definition of available command line arguments:

  • Audit inputs for consistency on language and style
  • Making options type safe
  • Logical grouping
  • Expanding and improving the help and usage explanations

For user output, SwiftPM outputs to the stdout and stderr, including progress indicators for operations like downloading or fetching dependencies.

When stdout is connected to a tty and the terminal supports it, SwiftPM uses ANSI escape codes to provide interactive progress-oriented output. When connected to a pipe, the output tends to be more focused on the actions taken and less on progress, since plain output is primarily used in Continuous Integration environments where issues have to be investigated after-the-fact.

Potential improvements is this context include:

  • Audit output options for consistency (e.g. output format option)
  • Improved progress indicators
  • Improved duration tracking and reporting
  • For concurrent work, present output from active task per worker / thread
  • Provide additional contextual information for warnings and errors
  • Graphical output for dependency graphs
  • General modernization the output - adopting modern CLI UX/UI best practices
2 Likes