rxiv-maker 1.16.1__py3-none-any.whl → 1.16.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
rxiv_maker/__version__.py CHANGED
@@ -1,3 +1,3 @@
1
1
  """Version information."""
2
2
 
3
- __version__ = "1.16.1"
3
+ __version__ = "1.16.2"
@@ -8,7 +8,7 @@ from ..framework import InitCommand
8
8
  @click.command(context_settings={"help_option_names": ["-h", "--help"]})
9
9
  @click.argument("manuscript_path", type=click.Path(), required=False)
10
10
  @click.option("--force", "-f", is_flag=True, help="Force overwrite existing files")
11
- @click.option("--no-interactive", is_flag=True, help="Skip interactive prompts and use defaults")
11
+ @click.option("--no-interactive", is_flag=True, hidden=True, help="Deprecated (command is always non-interactive)")
12
12
  @click.option(
13
13
  "--validate", is_flag=True, help="Run validation after initialization to ensure template builds correctly"
14
14
  )
@@ -25,6 +25,9 @@ def init(
25
25
  **MANUSCRIPT_PATH**: Directory to create for your manuscript.
26
26
  Defaults to MANUSCRIPT/
27
27
 
28
+ This command is fully non-interactive and uses sensible defaults for all values.
29
+ You can customize the manuscript details by editing 00_CONFIG.yml after initialization.
30
+
28
31
  Creates all required files including configuration, main content, supplementary
29
32
  information, bibliography, and figure directory with example scripts.
30
33
 
@@ -45,10 +48,6 @@ def init(
45
48
  **Initialize and validate template builds correctly:**
46
49
 
47
50
  $ rxiv init --validate
48
-
49
- **Non-interactive initialization:**
50
-
51
- $ rxiv init --no-interactive
52
51
  """
53
52
  # Use centralized InitCommand framework - eliminates 250+ lines of boilerplate!
54
53
  command = InitCommand()
@@ -5,12 +5,12 @@ import subprocess
5
5
  import sys
6
6
 
7
7
  import click
8
+ from henriqueslab_updater import force_update_check
8
9
  from rich.console import Console
9
10
 
10
11
  from ... import __version__
11
12
  from ...utils.changelog_parser import fetch_and_format_changelog
12
13
  from ...utils.install_detector import detect_install_method, get_friendly_install_name, get_upgrade_command
13
- from ...utils.update_checker import force_update_check
14
14
  from ..interactive import prompt_confirm
15
15
 
16
16
  console = Console()
@@ -210,6 +210,9 @@ class BaseCommand(ABC):
210
210
  return self.execute_operation(**kwargs)
211
211
 
212
212
  except CommandExecutionError as e:
213
+ # Print error message to stderr before exiting
214
+ error_console = Console(stderr=True)
215
+ error_console.print(f"❌ Error: {e}", style="red")
213
216
  sys.exit(e.exit_code)
214
217
  except KeyboardInterrupt:
215
218
  self.handle_keyboard_interrupt(operation_name)
@@ -50,44 +50,26 @@ class InitCommand(BaseCommand):
50
50
 
51
51
  Args:
52
52
  force: Force overwrite existing files
53
- no_interactive: Skip interactive prompts
53
+ no_interactive: Deprecated (command is always non-interactive)
54
54
  validate: Run validation after initialization
55
55
  template: Template type to use (default, minimal, journal, preprint)
56
56
  """
57
- from rich.prompt import Prompt
58
-
59
57
  # Get manuscript path from raw path (set during setup_common_options)
60
58
  manuscript_path = self.raw_manuscript_path
61
59
 
62
60
  manuscript_dir = Path(manuscript_path)
63
61
 
64
- # Check if directory exists
62
+ # Check if directory exists and fail if --force not used
65
63
  if manuscript_dir.exists() and not force:
66
- if not no_interactive:
67
- overwrite = Prompt.ask(
68
- f"Directory '{manuscript_path}' already exists. Overwrite?", choices=["y", "n"], default="n"
69
- )
70
- if overwrite == "n":
71
- self.console.print("❌ Initialization cancelled", style="yellow")
72
- return
73
- else:
74
- raise CommandExecutionError(f"Directory '{manuscript_path}' already exists. Use --force to overwrite.")
64
+ raise CommandExecutionError(f"Directory '{manuscript_path}' already exists. Use --force to overwrite.")
75
65
 
76
- # Get user information if interactive (BEFORE progress bar)
66
+ # Always use default values (non-interactive mode only)
77
67
  title = "Your Manuscript Title"
78
68
  author_name = "Your Name"
79
69
  author_email = "your.email@example.com"
80
70
  author_orcid = "0000-0000-0000-0000"
81
71
  author_affiliation = "Your Institution"
82
72
 
83
- if not no_interactive:
84
- self.console.print("\n📝 Enter manuscript details (press Enter for defaults):")
85
- title = Prompt.ask("Title", default=title)
86
- author_name = Prompt.ask("Author name", default=author_name)
87
- author_email = Prompt.ask("Author email", default=author_email)
88
- author_orcid = Prompt.ask("Author ORCID", default=author_orcid)
89
- author_affiliation = Prompt.ask("Author affiliation", default=author_affiliation)
90
-
91
73
  with self.create_progress() as progress:
92
74
  task = progress.add_task(f"Initializing manuscript (template: {template})...", total=2)
93
75
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rxiv-maker
3
- Version: 1.16.1
3
+ Version: 1.16.2
4
4
  Summary: Write scientific preprints in Markdown. Generate publication-ready PDFs efficiently.
5
5
  Project-URL: Homepage, https://github.com/HenriquesLab/rxiv-maker
6
6
  Project-URL: Documentation, https://github.com/HenriquesLab/rxiv-maker#readme
@@ -1,5 +1,5 @@
1
1
  rxiv_maker/__init__.py,sha256=p04JYC5ZhP6dLXkoWVlKNyiRvsDE1a4C88f9q4xO3tA,3268
2
- rxiv_maker/__version__.py,sha256=8DXr6AdO9lpjmX0V0QhmlTnYk_k3iaC056W7yqb_Jag,51
2
+ rxiv_maker/__version__.py,sha256=h4vGk0FuyrlvBrEgVAsEBcpJH8-ziWXS5OvVb5x9ykI,51
3
3
  rxiv_maker/rxiv_maker_cli.py,sha256=9Lu_mhFPXwx5jzAR6StCNxwCm_fkmP5qiOYdNuh_AwI,120
4
4
  rxiv_maker/validate.py,sha256=AIzgP59KbCQJqC9WIGfUdVv0xI6ud9g1fFznQkaGz5Q,9373
5
5
  rxiv_maker/cli/__init__.py,sha256=Jw0DTFUSofN-02xpVrt1UUzRcgH5NNd-GPNidhmNwpU,77
@@ -22,24 +22,24 @@ rxiv_maker/cli/commands/create_repo.py,sha256=jWPwT1Ai7XBhFAi9JmSAobdFYXPlSgQCD-
22
22
  rxiv_maker/cli/commands/docx.py,sha256=yFJxwDyQ8F6M9n4R6AUx0lq03iMQevuI_9eY2t6ke24,2849
23
23
  rxiv_maker/cli/commands/figures.py,sha256=WraC0BjwxKImzCwt1A3vWs8_T4w2misP1eeW6aznpCw,3250
24
24
  rxiv_maker/cli/commands/get_rxiv_preprint.py,sha256=nSPuFpS5xZ9VaUrmwnFZ5RCAAjj0ORAj8x_EJmH0Xtg,8543
25
- rxiv_maker/cli/commands/init.py,sha256=RLv9jLUYAZLNPjcvcVP3XzMtwl-hxVFNaf8oOD4iuEA,1680
25
+ rxiv_maker/cli/commands/init.py,sha256=2UiXtk7a5bklqwevWwhbL9lU1ASBxUwzm7JdrINHcGA,1797
26
26
  rxiv_maker/cli/commands/install_deps.py,sha256=7gE9EKwxkWxcsG5xlyMmIOpi4f0JAUqqvDviwkSIf8s,1724
27
27
  rxiv_maker/cli/commands/repo_init.py,sha256=FlAdxYi9ST01T47LUZ7zAytR7UkyKVn6MIC6cMRCbv0,6625
28
28
  rxiv_maker/cli/commands/repos.py,sha256=SQ9nuhSkyHKFPYn_TrOxyQoGdDRI-OBOgUSGJpRu0wo,6148
29
29
  rxiv_maker/cli/commands/repos_search.py,sha256=6sUMvyHlHEX1p88hPtu0_Hf8z6JpOinJ53l9ZI-rirc,7743
30
30
  rxiv_maker/cli/commands/setup.py,sha256=9ue4bDETpSPGVkWFDfpuTDsysax5-QKGxmt42Gb7oeU,2294
31
31
  rxiv_maker/cli/commands/track_changes.py,sha256=omf_77A7htRSa8naUEPTTtUTxrSwMpzHFOuU0j1xAJw,1163
32
- rxiv_maker/cli/commands/upgrade.py,sha256=7wgfAZisEisCqIBBQrNhc6IqcefmaSv4f-6IIaqno-I,7304
32
+ rxiv_maker/cli/commands/upgrade.py,sha256=5yA8Aa_zIwJ6PBE94NB_ZqRYhiQkawm-lc43u04NiYY,7301
33
33
  rxiv_maker/cli/commands/validate.py,sha256=3JghFQevJvQDQII4p_QWbQXMEUyDpM-t9-WxtaT4edo,1629
34
34
  rxiv_maker/cli/commands/version.py,sha256=VMlfSxxsrZH02d24MXLUDZfHBW39yZRpWxUpMhQ-X0Y,2737
35
35
  rxiv_maker/cli/framework/__init__.py,sha256=4FPXdP8J6v4eeEn46mwY0VtnwxjR1jnW_kTrXykQlQs,2704
36
- rxiv_maker/cli/framework/base.py,sha256=B9Lk8egK2rfAdD8g-EDQfrTF78fCMUBssB7FxF-AQ3I,7714
36
+ rxiv_maker/cli/framework/base.py,sha256=GcDFFOGVrLSlRgwDPmMkEAL60TbgT-maTyiCp1g-BrA,7886
37
37
  rxiv_maker/cli/framework/cache_commands.py,sha256=J91UYLTsLTRoNdzuhAbNL2bJJovYYfX3T9jI8cNUBWU,9897
38
38
  rxiv_maker/cli/framework/config_commands.py,sha256=a1uOQkCCw3d4qlro3OwHIorcoNg03T_R4-HbfVb-hmQ,19336
39
39
  rxiv_maker/cli/framework/content_commands.py,sha256=RilxKeG2c1m2fu0CtWAvP3cGh11DGx9P-nh2kIewAg4,22596
40
40
  rxiv_maker/cli/framework/decorators.py,sha256=fh085e3k1CaLSMoZevt8hvgnEuejrf-mcNS-dwXoY_A,10365
41
41
  rxiv_maker/cli/framework/utility_commands.py,sha256=_P_KwjlyiNS-vVboU-DqkHynGPqzXyoZRWGmLMLTnOs,26214
42
- rxiv_maker/cli/framework/workflow_commands.py,sha256=GbK1Wv4cTQfCiOyukn_R3q3IUqKvLk8MMK1vOXW3PaE,30556
42
+ rxiv_maker/cli/framework/workflow_commands.py,sha256=CFa3c5oJMmy9cUZxTAU97eKC6YrOljzerSAMrywjbKw,29684
43
43
  rxiv_maker/config/defaults.py,sha256=vHyLGVxe5-z9TLxu5f6NhquPvqQkER_KZv_j1I4_dHQ,3055
44
44
  rxiv_maker/config/validator.py,sha256=9XDPfo_YgasGt6NLkl6HIhaGh1fr6XsFNiXU2DSsivw,38299
45
45
  rxiv_maker/converters/__init__.py,sha256=d7WGsRwWqRQWO117IkKDP0Ap0ERiK0N2-dXHInye3_A,685
@@ -187,8 +187,8 @@ rxiv_maker/validators/doi/metadata_comparator.py,sha256=euqHhKP5sHQAdZbdoAahUn6Y
187
187
  rxiv_maker/tex/template.tex,sha256=zrJ3aFfu8j9zkg1l375eE9w-j42P3rz16wMD3dSgi1I,1354
188
188
  rxiv_maker/tex/style/rxiv_maker_style.bst,sha256=jbVqrJgAm6F88cow5vtZuPBwwmlcYykclTm8RvZIo6Y,24281
189
189
  rxiv_maker/tex/style/rxiv_maker_style.cls,sha256=F2qtnS9mI6SwOIaVH76egXZkB2_GzbH4gCTG_ZcfCDQ,24253
190
- rxiv_maker-1.16.1.dist-info/METADATA,sha256=A8awBHoNe4YS_8eJS9F2oNgbUoXpmy_sNgp6VsyRzXw,19818
191
- rxiv_maker-1.16.1.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
192
- rxiv_maker-1.16.1.dist-info/entry_points.txt,sha256=ghCN0hI9A1GlG7QY5F6E-xYPflA8CyS4B6bTQ1YLop0,97
193
- rxiv_maker-1.16.1.dist-info/licenses/LICENSE,sha256=GSZFoPIhWDNJEtSHTQ5dnELN38zFwRiQO2antBezGQk,1093
194
- rxiv_maker-1.16.1.dist-info/RECORD,,
190
+ rxiv_maker-1.16.2.dist-info/METADATA,sha256=V3WoTrIExIZesjZ8DAfQeZFUxr9-Pma4tmSGH13iiuw,19818
191
+ rxiv_maker-1.16.2.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
192
+ rxiv_maker-1.16.2.dist-info/entry_points.txt,sha256=ghCN0hI9A1GlG7QY5F6E-xYPflA8CyS4B6bTQ1YLop0,97
193
+ rxiv_maker-1.16.2.dist-info/licenses/LICENSE,sha256=GSZFoPIhWDNJEtSHTQ5dnELN38zFwRiQO2antBezGQk,1093
194
+ rxiv_maker-1.16.2.dist-info/RECORD,,