当前位置:网站首页>How can my Haskell program or library find its version number- How can my Haskell program or library find its version number?
How can my Haskell program or library find its version number- How can my Haskell program or library find its version number?
2022-07-06 19:16:00 【Superior virtue and weak water】
problem :
I would like my cabalised program to have a --version
switch. I hope my cabalised The program has a --version
Switch .
I would like it to report the same version as is present in the .cabal file. I hope it reports with .cabal The same version exists in the file .
If I have to update the version number separately in my Haskell source code as well as in the .cabal file, I will eventually get them out of sync. If I have to be in my Haskell The source code and .cabal The version number is updated separately in the document , I will eventually make them out of sync .
So, how can my program, while being compiled under cabal, get its version number from the .cabal file? that , How is my program in cabal Compile below , from .cabal Get its version number from the file ?
Solution :
Reference resources : https://stackoom.com/en/question/C8Uc边栏推荐
- MRO工业品企业采购系统:如何精细化采购协同管理?想要升级的工业品企业必看!
- Installation and management procedures
- QPushButton绑定快捷键的注意事项
- Xingnuochi technology's IPO was terminated: it was planned to raise 350million yuan, with an annual revenue of 367million yuan
- 五金机电行业供应商智慧管理平台解决方案:优化供应链管理,带动企业业绩增长
- [depth first search] Ji suanke: a joke of replacement
- GCC [7] - compilation checks the declaration of functions, and link checks the definition bugs of functions
- [matlab] Simulink the input and output variables of the same module cannot have the same name
- R language ggplot2 visualization: use the ggstripchart function of ggpubr package to visualize the grouped dot strip plot, and set the add parameter to add box plots for different levels of dot strip
- test about BinaryTree
猜你喜欢
RT-Thread 组件 FinSH 使用时遇到的问题
中缀表达式转后缀表达式详细思路及代码实现
pychrm社区版调用matplotlib.pyplot.imshow()函数图像不弹出的解决方法
提前解锁 2 大直播主题!今天手把手教你如何完成软件包集成?|第 29-30 期
Unlock 2 live broadcast themes in advance! Today, I will teach you how to complete software package integration Issues 29-30
Handwritten online chat system (principle part 1)
Druid 数据库连接池 详解
五金机电行业供应商智慧管理平台解决方案:优化供应链管理,带动企业业绩增长
Implementation of AVL tree
A full set of teaching materials, real questions of Android interview of 7 major manufacturers including Alibaba Kwai pinduoduo
随机推荐
C language daily practice - day 22: Zero foundation learning dynamic planning
R语言ggplot2可视化:使用ggpubr包的ggstripchart函数可视化分组点状条带图(dot strip plot)、设置add参数为不同水平点状条带图添加箱图
Fast power template for inverse element, the role of inverse element and example [the 20th summer competition of Shanghai University Programming League] permutation counting
wx小程序学习笔记day01
Optical blood pressure estimation based on PPG and FFT neural network [translation]
Pychrm Community Edition calls matplotlib pyplot. Solution of imshow() function image not popping up
基于蝴蝶种类识别
使用map函数、split函数一行键入多个元素
Handwritten online chat system (principle part 1)
How word displays modification traces
Php+redis realizes the function of canceling orders over time
Looting iii[post sequence traversal and backtracking + dynamic planning]
Mathematical knowledge -- code implementation of Gaussian elimination (elementary line transformation to solve equations)
[matlab] Simulink the input and output variables of the same module cannot have the same name
Qlabel marquee text display
倒计时2天|腾讯云消息队列数据接入平台(Data Import Platform)直播预告
php+redis实现超时取消订单功能
受益匪浅,安卓面试问题
中缀表达式转后缀表达式详细思路及代码实现
驼峰式与下划线命名规则(Camel case With hungarian notation)