IndianOpenSourceFoundation / dynamic-cli

A Modern, user-friendly command-line HTTP client for the API testing, and if you're stuck - Search and browse StackOverflow without leaving the CLI
https://pypi.org/project/dynamic-cli/
GNU General Public License v3.0
169 stars 120 forks source link

Copy button in the terminal #177 #186

Open Aspireve opened 1 year ago

Aspireve commented 1 year ago

Related Issue

The Issue was to create a button to Copy the code snipped straight into the clipboard of the computer

Closes: #177

Describe the changes you've made

To create a copy method I used the pyperclip library from python The part of selecting the text to copy was a bit complex so I had to make up an elaborate method to do so. The method I used works on all types of code, keeping the indentation constant aswell, for both spaces and tabs

Note : I also added a requirement to the requirement.txt

Checklist:

Screenshots

Original Updated
image image
Aspireve commented 1 year ago

Hey @GouravSardana do review it please

GouravSardana commented 1 year ago

@Aspireve can you please fix above warnings? These are from code scanner. You can use any plugin for pep8 and reformat the file and it’ll work

Aspireve commented 1 year ago

Yup Sure, give me a minute

sonarcloud[bot] commented 1 year ago

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

Aspireve commented 1 year ago

Aye there are a lot of errors, it'll take time, I'll solve it as soon as possible.