omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular

    Welcome!

    This is the community forum for my apps Pythonista and Editorial.

    For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.


    StaSh - Shell Like an Expert in Pythonista

    Pythonista
    21
    55
    213990
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • wradcliffe
      wradcliffe last edited by

      @whitone - Thanks for posting this. I have never used pip and my setup under Pythonista is now littered with many modules that I manually "installed". It is not hard, but I figured that there must be a better way. I also have no idea what monkey patches are about so I need to do some reading.

      If you have any cycles it would be very instructional to have one quick tutorial on a useful program you installed and converted and the patches you had to apply to get it working and how you now have this captured and automated using stash - pip, etc.

      One last question - are you referring to CLI programs in general or using the PyCLI module: https://pythonhosted.org/pyCLI/ ? This seems like a great way to go for writing scripts and gets people going using logging and a good command line interface.

      1 Reply Last reply Reply Quote 0
      • polymerchm
        polymerchm last edited by

        Monkey Patch

        1 Reply Last reply Reply Quote 0
        • briarfox
          briarfox last edited by

          @whitone Glad you find the pip module useful. It's still limited on which packages it can install but it manages most of the common ones. We have tried to stub out setuptool as best we can but there are so many use cases. Currently pip will simply look for a folder with the same name as the package and put it into site-packages. Then it will look for src/package_name and as a last resort will attempt to run the setup.

          I think @omz should add StaSh to the pythonista installation. It;s incredably useful and community developed. Props to @ywangd for creating such an awesome package.

          1 Reply Last reply Reply Quote 0
          • ywangd
            ywangd last edited by

            @whitone The one line installation is a great idea. If it is OK with you, I'll add it to the README file as part of the installation instruction. The great work of pip is done by @briarfox. StaSh is made better by the excellent contributions from the community.

            After seeing the discussions, I am thinking to have something like "Tip/Treasure of the day" when StaSh starts up. Seems to be a good way for users to discover some useful tools and features in a non-intrusive manner.

            1 Reply Last reply Reply Quote 0
            • briarfox
              briarfox last edited by

              @ywangd Tip of the day is a great idea, If I hadn't recently dove into linux command-line I'd be lost in staSh.

              1 Reply Last reply Reply Quote 0
              • brumm
                brumm last edited by

                Great tool, thank you.<br /><br />
                I want to ask if there is a trick using the find command?<br />
                I always get:<br />
                stash: IndentationError('unindent does not match any outer indentation level', ('findy.py', 148, 17, ...)<br /><br />
                [~/Documents]$ find . -name "*.py"

                1 Reply Last reply Reply Quote 0
                • oefe186
                  oefe186 last edited by

                  @brumm works for me. Probably you edited bin/find.py by accident. The original is 147 lines long, but the error message refers to line 148..,

                  1 Reply Last reply Reply Quote 0
                  • brumm
                    brumm last edited by

                    @oefe thank you 😀. My mistake...

                    1 Reply Last reply Reply Quote 0
                    • alport
                      alport last edited by

                      An amazingly useful piece of software - thank you very much.
                      I had been trying to get MQTT running on the iPad - didn't have any joy loading paho-mqtt but pip install mosquitto does seem to be OK so far.

                      1 Reply Last reply Reply Quote 0
                      • Webmaster4o
                        Webmaster4o last edited by

                        It'd be cool to use this to keep user themes in stash and get all pythonista's features

                        ywangd 1 Reply Last reply Reply Quote 0
                        • ywangd
                          ywangd @Webmaster4o last edited by

                          @Webmaster4o said:

                          It'd be cool to use this to keep user themes in stash and get all pythonista's features

                          I do plan to upgrade StaSh using the new and cool ctypes stuff. However, it may not use the Editor Internals as it is private and @omz does not recommend to use it seriously. So unless a more complete documentation about the Editor is available, I'll probably avoid using it.

                          1 Reply Last reply Reply Quote 0
                          • Webmaster4o
                            Webmaster4o last edited by

                            Ok. Sounds good, I look forward to it.

                            1 Reply Last reply Reply Quote 0
                            • eddo888
                              eddo888 last edited by

                              Simply the most wonderful thing to add to my iPhone
                              second to Pythonista of course :-)

                              1 Reply Last reply Reply Quote 0
                              • daveman
                                daveman last edited by

                                Hey does anyone no how to add an image in the background of stash. Like instead of changing background color you can add a background image ??????

                                1 Reply Last reply Reply Quote 0
                                • Webmaster4o
                                  Webmaster4o last edited by

                                  @daveman It's not possible without editing the source code (Having an image as a terminal background is stupid anyway, if you ask me :P)

                                  1 Reply Last reply Reply Quote 0
                                  • technoway
                                    technoway last edited by

                                    Thank you for writing this and sharing it. StaSh is great.

                                    1 Reply Last reply Reply Quote 0
                                    • ccc
                                      ccc last edited by

                                      Agreed! What prevents StaSH from being ported to Python 3?

                                      1 Reply Last reply Reply Quote 0
                                      • dgelessus
                                        dgelessus last edited by

                                        I don't think Stash depends on any Python 2-only libraries, it's just a relatively large Python 2 codebase that needs some work to port to Python 3.

                                        1 Reply Last reply Reply Quote 0
                                        • eddo888
                                          eddo888 @ywangd last edited by

                                          @ywangd pip tls 1.2 upgrade
                                          Hi, recently pypi enforced TLSv1.2 so now old TLSv1.0 clients can't connect. Could you please update the pip client to work with TLSv1.2 ?

                                          Cheers Dave.

                                          1 Reply Last reply Reply Quote 0
                                          • FarmerPaco
                                            FarmerPaco last edited by FarmerPaco

                                            Hi @ywangd
                                            Love Stash.

                                            Is there any reason I am getting ‘Repository/branch not found’ when running selfupdate?

                                            I’m on
                                            StaSh v0.6.19
                                            Pythonista 3.2 (320000)
                                            iOS 11.3.1 (64-bit iPad5,3)
                                            root: ~/Documents/site-packages/stash
                                            stash.py: 2018-01-01 12:59:22
                                            SELFUPDATE_BRANCH: master

                                            bennr01 1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post
                                            Powered by NodeBB Forums | Contributors