AminetAminet
Search:
84439 packages online
About
Recent
Browse
Search
Upload
Setup
Services

dev/src/echo.py.txt

Mirror:Random
Showing:m68k-amigaosppc-amigaosppc-morphosi386-arosi386-amithlonppc-warpupppc-powerupgeneric
No screenshot available
Short:An echo/printf function for Python
Author:wisecracker at tesco.net (Barry Walker)
Uploader:wisecracker tesco net (Barry Walker)
Type:dev/src
Version:1.00.00
Architecture:generic; m68k-amigaos
Date:2017-03-21
Download:http://aminet.net/dev/src/echo.py.txt - View contents
Readme:http://aminet.net/dev/src/echo.py.readme
Downloads:1044

Distribution: Public Domain, Emailware.

============================================================================

Architectures: Classic Stock AMIGA 1200, WinUAE, OSX 10.12.3. Windows 10,
               Linux and FS-UAE. (Perhaps even an old E-UAE.)

----------------------------------------------------------------------------

  MINIMUM Requirements Are:-
  --------------------------

  1) Amiga environment:-
       68EC020 CPU and 2MB RAM total, example, a standard A1200(HD).
       WinUAE, AF2005 minimum, FS-UAE.
       Standard OS3.0x install or better. 
       Full Python 1.4.x, minimum, installed.
       (Python 1.5.2 to 2.4.x are also available on AMINET along with
       Version 2.5.2 for AROS.)

  2) Windows environment:-
       Windows 10 using Python 3.6.0.

  3) Linux environment:-
       Linux Mint using various Python Versions.

  4) Apple OSX 10.12.x and higher from Python 2.6.9 to 3.5.2.

----------------------------------------------------------------------------

  History:-
  ---------

  21-03-2017.
  -----------
  Version 1.00.00. Probably the one and only upload for this archive.

----------------------------------------------------------------------------

  General:-
  ---------

TINY Python Version 1.4.0 echo() and/or printf() functions.

These give consitently exactly the same results on all versions of Python
from Version 1.4.0 to, NOW, 3.6.0 an just about ANY platform!

Just download the tiny file and rename from echo.py.txt to echo.py and place
into your PYTHON: volume.

(If you use it on *NIX style terminals you can still use the terminal escape
codes inside these functions. This includes a large subset in the default
AMIGA shell.)

To use, just enter at the Python 1.4.0 or greater prompt:-

>>> execfile("PYTHON:echo.py")

To test this echo() you WILL need to edit the [code] below from this readme
and also save in your PYTHON: volume...
[code]
# echo1.py

exec(open("PYTHON:echo.py").read())

newline="\n"
char="!"
num=1
strng1="Python Version "
strng2=".4.0 for the AMIGA to 3.5.x"

echo("This works from %s%u%s on any platform%c%c" %(strng1, num, strng2, char,
newline))
echo("A continuous ")
echo("line of 'echo's ")
echo("to show that no newline occurs, ")
echo("until now.\n")

# sys.stdout.flush()
[/code]
...and execute from the Python 1.4.0 or greater prompt:-

>>> execfile("PYTHON:echo1.py")
This works from Python Version 1.4.0 for the AMIGA to 3.5.x on any platform!
A continuous line of 'echo's to show that no newline occurs, until now.

Giving the two lines above...

Enjoy finding simple solutions to often difficult problems.

----------------------------------------------------------------------------

  This archive is issued under the CC0 licence.
 
----------------------------------------------------------------------------

                                IMPORTANT:-
                                -----------

    The Legal Stuff:-
    -----------------

    This code is CC0 licenced.

    The author is not responsible for any damage to, or loss of, or failure
    of equipment or data caused in any way by the use of these programs.

    There is NO warranty with the use of these software releases and
    YOU USE THEM AT YOUR OWN RISK.

----------------------------------------------------------------------------

    Testing Evaluation:-
    --------------------

    All WinUAE, FS-UAE and Classic AMIGA 1200(HD) test conditions were/are
    running standard OS3.0x/OS3.1x and using standard ~topaz 8~ fonts
    throughout.

    I have no idea what strange configuration setups will create so refer
    to the ~The Legal Stuff~ above.

----------------------------------------------------------------------------

   Contact:-
   ---------

   Mr Barry Walker, G0LCU.

   Email:-     wisecracker at tesco.net

   Author of the ~TestGear?~ projects in the ~docs/hard~ drawer of AMINET.

----------------------------------------------------------------------------

   A very useful HardWare related site, (C) Anthony Hoffman, for
   modifications, schematics, repairs and the like is:-

                          http://amiga.serveftp.net/

============================================================================



Aminet © 1992-2024 Urban Müller and the Aminet team. Aminet contact address: <aminetaminet net>