
from flask import Flask
import pybadges

app = Flask(__name__)


@app.route('/')
def serveBadges():
    # First example
    badge_arg = dict(
        left_text='build',
        right_text='passing',
        right_color='#008000'
    )
    badge = pybadges.badge(**badge_arg)

    # Second example
    secondBadge = pybadges.badge('chat', 'online')

    return badge + "\n" + secondBadge


if __name__ == '__main__':
    app.run()


""" Example CI server that serves badges """

from flask import Flask
import pybadges

app = Flask(__name__)


@app.route('/')
def serveBadges():
    # First example
    badge_arg = dict(
        left_text='build',
        right_text='passing',
        right_color='#008000')
    badge = pybadges.badge(**badge_arg)

    # Second example
    secondBadge = pybadges.badge('chat', 'online')
    return badge + "\n" + secondBadge


if __name__ == '__main__':
    app.run()

Add license, right comment and format code
Add license, right comment and format code

+ 
+ """ Example CI server that serves badges """
  
  from flask import Flask
  import pybadges
  
  app = Flask(__name__)
  
  
  @app.route('/')
  def serveBadges():
      # First example
      badge_arg = dict(
          left_text='build',
          right_text='passing',
-         right_color='#008000'
+         right_color='#008000')
-     )
      badge = pybadges.badge(**badge_arg)
  
      # Second example
      secondBadge = pybadges.badge('chat', 'online')
- 
      return badge + "\n" + secondBadge
  
  
  if __name__ == '__main__':
      app.run()
  
Add license, right comment and format code
## Code Before:

from flask import Flask
import pybadges

app = Flask(__name__)


@app.route('/')
def serveBadges():
    # First example
    badge_arg = dict(
        left_text='build',
        right_text='passing',
        right_color='#008000'
    )
    badge = pybadges.badge(**badge_arg)

    # Second example
    secondBadge = pybadges.badge('chat', 'online')

    return badge + "\n" + secondBadge


if __name__ == '__main__':
    app.run()

## Instruction:
Add license, right comment and format code
## Code After:

""" Example CI server that serves badges """

from flask import Flask
import pybadges

app = Flask(__name__)


@app.route('/')
def serveBadges():
    # First example
    badge_arg = dict(
        left_text='build',
        right_text='passing',
        right_color='#008000')
    badge = pybadges.badge(**badge_arg)

    # Second example
    secondBadge = pybadges.badge('chat', 'online')
    return badge + "\n" + secondBadge


if __name__ == '__main__':
    app.run()
