twtxt/cli.py
def unfollow(ctx, nick):
    """Remove an existing source from your followings."""
    source = ctx.obj['conf'].get_source_by_nick(nick)

    try:
        with Cache.discover() as cache:
            cache.remove_tweets(source.url)
    except OSError as e:
        logger.debug(e)

    ret_val = ctx.obj['conf'].remove_source_by_nick(nick)
    if ret_val:
        click.echo("✓ You’ve unfollowed {0}.".format(
            click.style(source.nick, bold=True)))
    else:
        click.echo("✗ You’re not following {0}.".format(
            click.style(nick, bold=True)))
def unfollow(ctx, nick):
    """Remove an existing source from your followings."""
    source = ctx.obj['conf'].get_source_by_nick(nick)

    try:
        with Cache.discover() as cache:
            cache.remove_tweets(source.url)
    except OSError as e:
        logger.debug(e)

    ret_val = ctx.obj['conf'].remove_source_by_nick(nick)
    if ret_val:
        click.echo("✓ You’ve unfollowed {0}.".format(
            click.style(source.nick, bold=True)))
    else:
        click.echo("✗ You’re not following {0}.".format(
            click.style(nick, bold=True)))
def unfollow ( ctx , nick ) : source = ctx . obj [ 'conf' ] . get_source_by_nick ( nick ) try : with Cache . discover ( ) as cache : cache . remove_tweets ( source . url ) except OSError as e : logger . debug ( e ) ret_val = ctx . obj [ 'conf' ] . remove_source_by_nick ( nick ) if ret_val : click . echo ( "✓ You’ve unfollowed {0}.".for m at( click . style ( source . nick , bold = True ) ) ) else : click . echo ( "✗ You’re not following {0}.".for m at( click . style ( nick , bold = True ) ) )
Remove an existing source from your followings.
Remove an existing source from your followings .