GithubHelp home page GithubHelp logo

chaofeng's Introduction

cháofēng

Cháofēng is a simple telnet bbs framework for python

更多的文档写在wiki里.

Hello, world

Here is a simple example app for Chaofeng :

from chaofeng import Frame, Server
import chaofeng.ascii as c

class Hello(Frame):

    def initialize(self):
        self.write('Hello,World!')
        self.close()

    def clear(self):
        self.write('Don leave me alone ...\r\n')

if __name__ == '__main__' :
    s = Server(Hello)
    s.run()

作为服务器,你可以这样运行:

python /path-to-the-file/

作为客户端,你可以这样(在linux):

telnet host port

一般的,本地的host是填loaclhost,port是5000。所以如果服务器是本地的话,你可以:

telnet localhost 5000

chaofeng's People

Stargazers

 avatar

Watchers

 avatar

Forkers

argomaintainer

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.