name_plus 0.0.1 copy "name_plus: ^0.0.1" to clipboard
name_plus: ^0.0.1 copied to clipboard

outdated

Automatically increment File & Directory name and create.

example/name_plus_example.dart

import 'dart:io';

import 'package:name_plus/name_plus.dart';

void main() {
  /// File

  /// without sync
  File(Directory.current.path).namePlus('test.txt');
  // test 1.txt

  File(Directory.current.path).namePlus('test.txt', format: '(d)');
  // test (1).txt

  File(Directory.current.path).namePlus('test.txt', space: false);
  // test1.txt

  /// with sync
  File(Directory.current.path).namePlusSync('test.txt');
  // test 1.txt

  /// Directory

  /// without sync
  Directory(Directory.current.path).namePlus('test');
  // test 1

  Directory(Directory.current.path).namePlus('test', format: '(d)');
  // test (1)

  Directory(Directory.current.path).namePlus('test', space: false);
  // test1

  /// with sync
  Directory(Directory.current.path).namePlusSync('test');
  // test 1
}
3
likes
0
pub points
74%
popularity

Publisher

unverified uploader

Automatically increment File & Directory name and create.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

path

More

Packages that depend on name_plus