pyeasyphd 0.1.5__tar.gz → 0.1.6__tar.gz

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.

Potentially problematic release.


This version of pyeasyphd might be problematic. Click here for more details.

Files changed (43) hide show
  1. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/PKG-INFO +2 -2
  2. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/pyeasyphd.sublime-settings +8 -4
  3. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/py_run_bib_md_tex.py +23 -7
  4. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/search_base.py +0 -1
  5. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/search_writers.py +0 -2
  6. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyproject.toml +2 -2
  7. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/README.md +0 -0
  8. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/.python-version +0 -0
  9. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/Main.sublime-menu +0 -0
  10. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/__init__.py +0 -0
  11. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/CSL/apa-no-ampersand.csl +0 -0
  12. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/CSL/apa.csl +0 -0
  13. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/CSL/ieee.csl +0 -0
  14. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Article.tex +0 -0
  15. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Article_Header.tex +0 -0
  16. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Article_Tail.tex +0 -0
  17. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Beamer_Header.tex +0 -0
  18. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Beamer_Tail.tex +0 -0
  19. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/Style.tex +0 -0
  20. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/TEVC_Header.tex +0 -0
  21. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/TEVC_Tail.tex +0 -0
  22. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/eisvogel.beamer +0 -0
  23. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/eisvogel.latex +0 -0
  24. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/eisvogel.tex +0 -0
  25. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/math.tex +0 -0
  26. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/data/Templates/TEX/math_commands.tex +0 -0
  27. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/main/__init__.py +0 -0
  28. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/main/basic_input.py +0 -0
  29. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/main/pandoc_md_to.py +0 -0
  30. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/main/python_run_md.py +0 -0
  31. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/main/python_run_tex.py +0 -0
  32. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/pyeasyphd.py +0 -0
  33. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/pyeasyphd.sublime-syntax +0 -0
  34. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/__init__.py +0 -0
  35. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/generate/generate_from_bibs.py +0 -0
  36. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/generate/generate_html.py +0 -0
  37. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/generate/generate_library.py +0 -0
  38. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/generate/generate_links.py +0 -0
  39. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/data.py +0 -0
  40. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/search_core.py +0 -0
  41. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/search_keywords.py +0 -0
  42. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/tools/search/utils.py +0 -0
  43. {pyeasyphd-0.1.5 → pyeasyphd-0.1.6}/pyeasyphd/utils/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyeasyphd
3
- Version: 0.1.5
3
+ Version: 0.1.6
4
4
  Summary: pyeasyphd
5
5
  License: GPL-3.0-or-later
6
6
  Keywords: Python,Markdown,LaTex
@@ -15,7 +15,7 @@ Classifier: Programming Language :: Python :: 3.13
15
15
  Classifier: Programming Language :: Python :: 3.14
16
16
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
17
17
  Requires-Dist: pyadvtools (>=0.1.5,<0.2.0)
18
- Requires-Dist: pybibtexer (>=0.1.5,<0.2.0)
18
+ Requires-Dist: pybibtexer (>=0.1.6,<0.2.0)
19
19
  Project-URL: Documentation, https://github.com/NextArtifIntell/pyeasyphd
20
20
  Project-URL: Homepage, https://github.com/NextArtifIntell/pyeasyphd
21
21
  Project-URL: Repository, https://github.com/NextArtifIntell/pyeasyphd
@@ -46,15 +46,19 @@
46
46
  ],
47
47
 
48
48
  // pyeasyphd/tools/python_run_latex_md.py
49
+ // Path to bibliographic data, can be either a directory path or a specific file path
50
+ "bib_path_or_file": "",
51
+
52
+ // Path to the figures directory (must be a directory path, not a file)
53
+ "figures_directory": "",
54
+ // ture, false
55
+ "shutil_figures": true,
56
+
49
57
  // true, false
50
58
  "generate_html": false,
51
-
52
59
  // true, false
53
60
  "generate_tex": true,
54
61
 
55
- // ture, false
56
- "shutil_figures": true,
57
-
58
62
  // for figure, bib, tex, and md
59
63
  "figure_folder_name": "fig", // "" or "figs" or "main"
60
64
  "bib_folder_name": "bib", // "" or "bibs" or "main"
@@ -18,7 +18,11 @@ class PyRunBibMdTex(BasicInput):
18
18
  """
19
19
 
20
20
  def __init__(
21
- self, path_output: str, tex_md_flag: str = ".md", template_name: str = "paper", options: Dict[str, Any] = {}
21
+ self,
22
+ path_output: str,
23
+ tex_md_flag: str = ".md",
24
+ template_name: str = "paper",
25
+ options: Dict[str, Any] = {}
22
26
  ) -> None:
23
27
  """Initialize the PyRunBibMdTex instance.
24
28
 
@@ -39,13 +43,18 @@ class PyRunBibMdTex(BasicInput):
39
43
  assert self.template_name in ["paper", "beamer"], f"{template_name} must be `paper` or `beamer`."
40
44
  self.path_output = standard_path(path_output)
41
45
 
42
- self.path_bibs = ""
43
- self.path_figures = ""
46
+ # Bib
47
+ # Path to bibliographic data, can be either a directory path or a specific file path
48
+ self.bib_path_or_file = options.get("bib_path_or_file", "")
49
+
50
+ # Figures
51
+ # Path to the figures directory (must be a directory path, not a file)
52
+ self.figures_directory = options.get("figures_directory", "")
53
+ self.shutil_figures = options.get("shutil_figures", True)
44
54
 
45
55
  # Configuration options
46
56
  self.generate_html = options.get("generate_html", False)
47
57
  self.generate_tex = options.get("generate_tex", True)
48
- self.shutil_figures = options.get("shutil_figures", True)
49
58
 
50
59
  # Folder name configurations
51
60
  self.figure_folder_name = options.get("figure_folder_name", "fig") # "" or "figs" or "main"
@@ -89,7 +98,7 @@ class PyRunBibMdTex(BasicInput):
89
98
  data_list_md_tex = combine_content_in_list(data_list_list, ["\n"])
90
99
 
91
100
  content_md, content_tex = self.python_run_bib_md_tex(
92
- output_prefix, data_list_md_tex, self.path_bibs, output_level
101
+ output_prefix, data_list_md_tex, self.bib_path_or_file, output_level
93
102
  )
94
103
  return content_md, content_tex
95
104
 
@@ -161,7 +170,7 @@ class PyRunBibMdTex(BasicInput):
161
170
  # Copy figures if enabled
162
171
  if self.shutil_figures:
163
172
  figure_names = self.search_figure_names(data_list_md_tex)
164
- self.shutil_copy_figures(self.figure_folder_name, self.path_figures, figure_names, self.path_output)
173
+ self.shutil_copy_figures(self.figure_folder_name, self.figures_directory, figure_names, self.path_output)
165
174
 
166
175
  # Extract citation keys from content
167
176
  key_in_md_tex = self.search_cite_keys(data_list_md_tex, self.tex_md_flag)
@@ -258,8 +267,11 @@ class PyRunBibMdTex(BasicInput):
258
267
  fig_names (List[str]): List of figure filenames to copy.
259
268
  path_output (str): Output directory path.
260
269
  """
270
+ if not fig_names:
271
+ return None
272
+
261
273
  if not os.path.exists(path_fig):
262
- print(f"{path_fig} does not existed.")
274
+ print(f"The specified figure directory: {path_fig} does not exist.")
263
275
  return None
264
276
 
265
277
  file_list = []
@@ -268,6 +280,10 @@ class PyRunBibMdTex(BasicInput):
268
280
  if name in fig_names:
269
281
  file_list.append(os.path.join(root, name))
270
282
 
283
+ not_founded_figures = list(set([os.path.basename(f) for f in file_list]).intersection(set(fig_names)))
284
+ if not_founded_figures:
285
+ print(f"Figures: {', '.join(not_founded_figures)} could not be found.")
286
+
271
287
  for file in file_list:
272
288
  path_output_file = os.path.join(path_output, fig_folder_name, os.path.basename(file))
273
289
  p = os.path.dirname(path_output_file)
@@ -62,7 +62,6 @@ class SearchInitialResult(BasicInput):
62
62
  Args:
63
63
  options (dict): Configuration options.
64
64
  """
65
- self.options = options
66
65
  super().__init__(options)
67
66
 
68
67
  self.print_on_screen: bool = options.get("print_on_screen", False)
@@ -28,8 +28,6 @@ class WriteInitialResult(BasicInput):
28
28
  """
29
29
  super().__init__(options)
30
30
 
31
- self.options = options
32
-
33
31
  self._level_title_md = "###"
34
32
  self._level_title_tex = "subsection"
35
33
  self._pandoc_md_to = PandocMdTo(options)
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pyeasyphd"
3
- version = "0.1.5"
3
+ version = "0.1.6"
4
4
  description = "pyeasyphd"
5
5
  license = "GPL-3.0-or-later"
6
6
  authors = ["NextAI <nextartifintell@gmail.com>"]
@@ -15,7 +15,7 @@ classifiers = ["Topic :: Software Development :: Libraries :: Python Modules"]
15
15
  [tool.poetry.dependencies]
16
16
  python = ">=3.13"
17
17
  pyadvtools = "^0.1.5"
18
- pybibtexer = "^0.1.5"
18
+ pybibtexer = "^0.1.6"
19
19
 
20
20
  [tool.poetry.group.dev.dependencies]
21
21
  mypy = "^1.18.1"
File without changes